Hi,
as soon as I enable vsync in the emulator settings, the emulator hangs after a few seconds/minutes. It´s not the whole system because I can kill the task using putty and then return back to EmulationStation, but the emulator itself remains unreactive (the RetroArch menu e.g. also does not show). However, it does not happen on all cores - I did not see problems e.g. with Stella and FCEUmm in RetroArch, but with ParallelN64, BeetlePSX as well as non-RetroArch emulators like Dolphin and FS-UAE.
My system, running the latest Batocera, is an old, but emulation-wise powerful AMD FX4300 (compared e.g. to an Raspi3 😉) on an 780G/SB700 chipset mainboard with 4GByte RAM. The graphics card is an AMD Radeon R9 280x - AFAIK the most powerful AMD card with DVI-I that can be connected to a CRT via DVI-/VGA-to-RGB connector.
On the exact same hardware, I installed Win10 for diagnostic purposes and let a burn-in benchmark run for >1h and also tested Dolphin with Vsync enabled without problems, so I believe that this problem is Linux kernel or driver specific.
Currently, I think it is related to this line in the Xorg.0.og, but could not find a solution yet on the web:
(EE) RADEON(0): drmmode_do_crtc_dpms cannot get last vblank counter
This line is always shown when starting an application that has Vsync enabled.
Some more lines:
[ 5.467] (II) RADEON(0): Creating default Display subsection in Screen section
"Default Screen Section" for depth/fbbpp 24/32
[ 5.467] (==) RADEON(0): Depth 24, (--) framebuffer bpp 32
[ 5.467] (II) RADEON(0): Pixel depth = 24 bits stored in 4 bytes (32 bpp pixmaps)
[ 5.467] (==) RADEON(0): Default visual is TrueColor
[ 5.467] (==) RADEON(0): RGB weight 888
[ 5.467] (II) RADEON(0): Using 8 bits per RGB (8 bit DAC)
[ 5.467] (--) RADEON(0): Chipset: "TAHITI" (ChipID = 0x6798)
[ 5.957] (II) Module glamoregl: vendor="X.Org Foundation"
[ 5.957] compiled for 1.20.6, module version = 1.0.1
[ 5.958] ABI class: X.Org ANSI C Emulation, version 0.4
[ 6.137] (II) RADEON(0): glamor X acceleration enabled on AMD TAHITI (DRM 2.50.0, 5.4.32, LLVM 9.0.0)
[ 6.137] (II) RADEON(0): glamor detected, initialising EGL layer.
[ 6.137] (II) RADEON(0): KMS Color Tiling: enabled
[ 6.137] (II) RADEON(0): KMS Color Tiling 2D: enabled
[ 6.137] (==) RADEON(0): TearFree property default: auto
[ 6.137] (II) RADEON(0): KMS Pageflipping: enabled
[ 6.168] (II) RADEON(0): Output DisplayPort-0 has no monitor section
[ 6.170] (II) RADEON(0): Output HDMI-0 has no monitor section
[ 6.171] (II) RADEON(0): Output DVI-0 has no monitor section
[ 6.190] (II) RADEON(0): Output DVI-1 has no monitor section
[ 6.220] (II) RADEON(0): EDID for output DisplayPort-0
[ 6.221] (II) RADEON(0): EDID for output HDMI-0
[ 6.223] (II) RADEON(0): EDID for output DVI-0
[ 6.238] (II) RADEON(0): EDID for output DVI-1
[ 6.238] (II) RADEON(0): Printing probed modes for output DVI-1
[ 6.238] (II) RADEON(0): Modeline "1024x768"x60.0 65.00 1024 1048 1184 1344 768 771 777 806 -hsync -vsync (48.4 kHz e)
[ 6.238] (II) RADEON(0): Modeline "800x600"x60.3 40.00 800 840 968 1056 600 601 605 628 +hsync +vsync (37.9 kHz e)
[ 6.238] (II) RADEON(0): Modeline "800x600"x56.2 36.00 800 824 896 1024 600 601 603 625 +hsync +vsync (35.2 kHz e)
[ 6.238] (II) RADEON(0): Modeline "848x480"x60.0 33.75 848 864 976 1088 480 486 494 517 +hsync +vsync (31.0 kHz e)
[ 6.238] (II) RADEON(0): Modeline "640x480"x59.9 25.18 640 656 752 800 480 490 492 525 -hsync -vsync (31.5 kHz e)
[ 6.238] (II) RADEON(0): Output DisplayPort-0 disconnected
[ 6.238] (II) RADEON(0): Output HDMI-0 disconnected
[ 6.238] (II) RADEON(0): Output DVI-0 disconnected
[ 6.238] (II) RADEON(0): Output DVI-1 connected
[ 6.238] (II) RADEON(0): Using exact sizes for initial modes
[ 6.238] (II) RADEON(0): Output DVI-1 using initial mode 1024x768 +0+0
[ 6.238] (II) RADEON(0): mem size init: gart size :7fbcc000 vram size: s:c0000000 visible:f728000
[ 6.238] (==) RADEON(0): DPI set to (96, 96)
[ 6.238] (==) RADEON(0): Using gamma correction (1.0, 1.0, 1.0)
[ 6.239] (II) RADEON(0): [DRI2] Setup complete
[ 6.239] (II) RADEON(0): [DRI2] DRI driver: radeonsi
[ 6.239] (II) RADEON(0): [DRI2] VDPAU driver: radeonsi
[ 6.240] (II) RADEON(0): Front buffer size: 3072K
[ 6.240] (II) RADEON(0): VRAM usage limit set to 224928K
[ 6.242] (II) RADEON(0): SYNC extension fences enabled
[ 6.243] (II) RADEON(0): Present extension enabled
[ 6.243] (==) RADEON(0): DRI3 enabled
[ 6.243] (==) RADEON(0): Backing store enabled
[ 6.243] (II) RADEON(0): Direct rendering enabled
[ 6.312] (II) RADEON(0): Use GLAMOR acceleration.
[ 6.312] (II) RADEON(0): Acceleration enabled
[ 6.312] (==) RADEON(0): DPMS enabled
[ 6.312] (==) RADEON(0): Silken mouse enabled
[ 6.312] (II) RADEON(0): Set up textured video (glamor)
[ 6.313] (II) RADEON(0): [XvMC] Associated with GLAMOR Textured Video.
[ 6.313] (II) RADEON(0): [XvMC] Extension initialized.
Do you have any hints, maybe at least on how to continue the investigation?
Thanks a lot in advance!