When trying to compile Valgrind with Clang on s390x, there are multiple errors: (1) "scalar-to-vector conversion failed, possible invalid constraint for vector type" -- in various inline-assemblies where an unsigned long is passed to an "f" constraint. (2) "register expected" -- in an inline assembly where the notation "r11" for a general register is used. (3) "invalid operand in inline asm: 'svc ${1:b}" -- in an inline assembly where a "b" modifier is used for a constant. (4) "__builtin_setjmp is not supported for the current target" -- when expanding the VG_MINIMAL_SETJMP/LONGJMP macros.
Created attachment 157848 [details] Enable compiling Valgrind with clang This enables compiling Valgrind with Clang, excluding the s390-specific test cases. I'm working on another patch for the test cases, but that will be more extensive.
(In reply to Andreas Arnez from comment #1) > Created attachment 157848 [details] > Enable compiling Valgrind with clang I pushed the above. Now clang should compile Valgrind for s390x successfully, except for the test cases.
I also pushed various patches for the test cases. While I've still seen Clang-specific issues with test case results, at least Valgrind can now be fully built with Clang for s390x. In my view, further test case fixes are out of the scope of this Bug. So I consider this fixed.