Skip to content
Commit c4e5c229 authored by Vasily Gorbik's avatar Vasily Gorbik
Browse files

s390/jump_label: use "i" constraint for clang



Currently kernel build fails under clang if jump labels are enabled.
The problem is "X" constraint usage "Any operand whatsoever is allowed",
for which clang produces the following:
.pushsection __jump_table,"aw"
.balign 8
.long   0b-.,.Ltmp577-.
.quad   %r0+0-. # %r0 is not allowed here
.popsection

Under gcc constraints "X" or "jdd" (gcc > 9) are used for static keys.
Ideally, we'd have used "i" for gcc, but it doesn't work in all cases
with -fPIC code. This is gcc-specific problem that doesn't exist in llvm.
Since clang does not have "jdd" simply always use "i" constraint for it.

Suggested-by: default avatarUlrich Weigand <ulrich.weigand@de.ibm.com>
Acked-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: default avatarVasily Gorbik <gor@linux.ibm.com>
parent ee09c914
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment