-
Notifications
You must be signed in to change notification settings - Fork 15
clang ias: build failure for arch/arm/probes/kprobes/test-arm.c #1271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
cc @jcai19 |
is this with clang-11? I get a different set of failures in this TU with clang-12 for allmodconfig.
|
For my case, |
I wonder if this is unified syntax issue? I'm re-writing it...slowly... |
damn, I have this finished, but there is one bug in LLVM that I have a fix for too... |
llvm patch: diff --git a/llvm/lib/Target/ARM/ARMInstrInfo.td b/llvm/lib/Target/ARM/ARMInstrInfo.td
index 8dcb319923ae..9792586a53a5 100644
--- a/llvm/lib/Target/ARM/ARMInstrInfo.td
+++ b/llvm/lib/Target/ARM/ARMInstrInfo.td
@@ -3579,10 +3579,10 @@ def MOVr_TC : AsI1<0b1101, (outs tcGPR:$Rd), (ins tcGPR:$Rm), DPFrm,
let Inst{15-12} = Rd;
}
-def MOVsr : AsI1<0b1101, (outs GPRnopc:$Rd), (ins shift_so_reg_reg:$src),
+def MOVsr : AsI1<0b1101, (outs GPR:$Rd), (ins shift_so_reg_reg:$src),
DPSoRegRegFrm, IIC_iMOVsr,
"mov", "\t$Rd, $src",
- [(set GPRnopc:$Rd, shift_so_reg_reg:$src)]>, UnaryDP,
+ [(set GPR:$Rd, shift_so_reg_reg:$src)]>, UnaryDP,
Sched<[WriteALU]> {
bits<4> Rd;
bits<12> src;
@@ -6327,16 +6327,16 @@ def RRXi : ARMAsmPseudo<"rrx${s}${p} $Rd, $Rm",
(ins GPR:$Rd, GPR:$Rm, pred:$p, cc_out:$s)>;
let TwoOperandAliasConstraint = "$Rn = $Rd" in {
def ASRr : ARMAsmPseudo<"asr${s}${p} $Rd, $Rn, $Rm",
- (ins GPRnopc:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
+ (ins GPR:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
cc_out:$s)>;
def LSRr : ARMAsmPseudo<"lsr${s}${p} $Rd, $Rn, $Rm",
- (ins GPRnopc:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
+ (ins GPR:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
cc_out:$s)>;
def LSLr : ARMAsmPseudo<"lsl${s}${p} $Rd, $Rn, $Rm",
- (ins GPRnopc:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
+ (ins GPR:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
cc_out:$s)>;
def RORr : ARMAsmPseudo<"ror${s}${p} $Rd, $Rn, $Rm",
- (ins GPRnopc:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
+ (ins GPR:$Rd, GPRnopc:$Rn, GPRnopc:$Rm, pred:$p,
cc_out:$s)>;
} kernel patch: |
@arndb I tried with stock LLVM and it was able to assemble |
On Thu, Jan 28, 2021 at 10:10 AM Jian Cai ***@***.***> wrote:
@arndb <https://github.com/arndb> I tried with stock LLVM and it was able
to assemble .ascii "and" "cs" "" " r2, r" "3" ", r" "2" ", lsr #458. The
support to space in .ascii was first added to IAS in llvm/llvm-project@
e0963ae <llvm/llvm-project@e0963ae274be>, but
got temporarily reverted at ***@***.***
<llvm/llvm-project@82c4153e66fa> for a test
failure (which turned out to be a false-positive). It was then relanded
again in ***@***.***
<llvm/llvm-project@9dfeec8>.
Is it possible that the Clang version you used fell into this range?
I was initially building with clang-11 by accident, retrying with Ubuntu
clang version
12.0.0-++20210126052625+879c12d95a27-1~exp1~20210126163340.296 now.
|
@arndb noted that arch/arm/probes/kprobes/test-thumb.c also has a similar issue with CONFIG_THUMB2_KERNEL. |
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. This exposed a bug in Clang's integrated assembler, which hopefully will land in clang-12, but is required to test this patch with LLVM_IAS=1. Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux#1271 Link: https://reviews.llvm.org/D95586 Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]>
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. This exposed a bug in Clang's integrated assembler, which hopefully will land in clang-12, but is required to test this patch with LLVM_IAS=1. Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux#1271 Link: https://reviews.llvm.org/D95586 Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]>
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. This exposed a bug in Clang's integrated assembler, which hopefully will land in clang-12, but is required to test this patch with LLVM_IAS=1. Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux#1271 Link: https://reviews.llvm.org/D95586 Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]>
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. movs pc, r1, lsl r2 is converted to be open coded via __inst_arm. The resolution of a discussion on the below linked discussion on an LLVM patch was that this form of this instruction is unpredictable, and should not be supported by LLVM. Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux#1271 Link: https://reviews.llvm.org/D95586 Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]>
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Link: ClangBuiltLinux#1271 Link: https://reviews.llvm.org/D95586 Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]>
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux#1271 Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]>
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Change-Id: I0b5a5c5ccb963e3a54611c8077ec108001328d81 Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ (cherry picked from commit 27866eb) Signed-off-by: TogoFire <[email protected]>
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Change-Id: I481191e29bc74f0e90eaa726a97a2c9c9fcd8957 Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ (cherry picked from commit e229ab3) Signed-off-by: TogoFire <[email protected]>
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8 Signed-off-by: Saad <[email protected]>
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363 Signed-off-by: Saad <[email protected]>
GNU as warns twice for this file: Warning: using r15 results in unpredictable behaviour via the Arm ARM: K1.1.1 Overview of the constraints on Armv7 UNPREDICTABLE behaviors The term UNPREDICTABLE describes a number of cases where the architecture has a feature that software must not use. Ard notes: These are selftests that aim to ensure that kprobe never attempts to replace the opcodes in question with a probe, but they are not actually executed, or expected to occur in real code. Reported-by: kernelci.org bot <[email protected]> Suggested-by: Peter Smith <[email protected]> Suggested-by: Renato Golin <[email protected]> Suggested-by: David Spickett <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: ClangBuiltLinux/linux#1271 Link: https://reviews.llvm.org/D95586 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: I42333d7e64a98f739ab13916f61a587143fec7f8
Clang's integrated assembler only accepts UAL syntax, rewrite the instructions that were changed by RVCTv2.1. The document "Assembly language changes after RVCTv2.1" was very helpful. .syntax unified directive is added, since -masm-syntax-unified is unreliable for older but supported versions of GCC. See also: commit fe09d9c ("ARM: 8852/1: uaccess: use unified assembler language syntax") Reported-by: Arnd Bergmann <[email protected]> Signed-off-by: Nick Desaulniers <[email protected]> Reviewed-by: Nathan Chancellor <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://developer.arm.com/documentation/dui0473/c/writing-arm-assembly-language/assembly-language-changes-after-rvctv2-1 Link: ClangBuiltLinux/linux#1271 Bug: 141693040 Link: https://lore.kernel.org/linux-arm-kernel/[email protected]/ Change-Id: Icbd266fce538460c64900e2fa0f032561e208363
This is the failure I get for this file when CONFIG_ARM_KPROBES_TEST is enabled
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:131:2: error: unexpected token in '.ascii' directive
DATA_PROCESSING_DNM("and",0xf00f00ff)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:81:2: note: expanded from macro 'DATA_PROCESSING_DNM'
_DATA_PROCESSING_DNM(op,"",val)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:58:2: note: expanded from macro '_DATA_PROCESSING_DNM'
TEST_RR( op "eq" s " r0, r",1, VAL1,", r",2, val, "")
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:239:2: note: expanded from macro 'TEST_RR'
TESTCASE_START(code1 #reg1 code2 #reg2 code3)
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:113:14: note: expanded from macro 'TESTCASE_START'
"10: \n\t"
^
:4:15: note: instantiated into assembly here
.ascii "and" "eq" "" " r0, r" "1" ", r" "2" ""
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:131:2: error: unexpected token in '.ascii' directive
DATA_PROCESSING_DNM("and",0xf00f00ff)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:81:2: note: expanded from macro 'DATA_PROCESSING_DNM'
_DATA_PROCESSING_DNM(op,"",val)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:59:2: note: expanded from macro '_DATA_PROCESSING_DNM'
TEST_RR( op "ne" s " r1, r",1, VAL1,", r",2, val, ", lsl #3")
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:239:2: note: expanded from macro 'TEST_RR'
TESTCASE_START(code1 #reg1 code2 #reg2 code3)
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:113:14: note: expanded from macro 'TESTCASE_START'
"10: \n\t"
^
:4:15: note: instantiated into assembly here
.ascii "and" "ne" "" " r1, r" "1" ", r" "2" ", lsl #3"
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:131:2: error: unexpected token in '.ascii' directive
DATA_PROCESSING_DNM("and",0xf00f00ff)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:81:2: note: expanded from macro 'DATA_PROCESSING_DNM'
_DATA_PROCESSING_DNM(op,"",val)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:60:2: note: expanded from macro '_DATA_PROCESSING_DNM'
TEST_RR( op "cs" s " r2, r",3, VAL1,", r",2, val, ", lsr #4")
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:239:2: note: expanded from macro 'TEST_RR'
TESTCASE_START(code1 #reg1 code2 #reg2 code3)
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:113:14: note: expanded from macro 'TESTCASE_START'
"10: \n\t"
^
:4:15: note: instantiated into assembly here
.ascii "and" "cs" "" " r2, r" "3" ", r" "2" ", lsr #4"
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:131:2: error: unexpected token in '.ascii' directive
DATA_PROCESSING_DNM("and",0xf00f00ff)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:81:2: note: expanded from macro 'DATA_PROCESSING_DNM'
_DATA_PROCESSING_DNM(op,"",val)
^
/git/arm-soc/arch/arm/probes/kprobes/test-arm.c:61:2: note: expanded from macro '_DATA_PROCESSING_DNM'
TEST_RR( op "cc" s " r3, r",3, VAL1,", r",2, val, ", asr #5")
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:239:2: note: expanded from macro 'TEST_RR'
TESTCASE_START(code1 #reg1 code2 #reg2 code3)
^
/git/arm-soc/arch/arm/probes/kprobes/test-core.h:113:14: note: expanded from macro 'TESTCASE_START'
"10: \n\t"
^
:4:15: note: instantiated into assembly here
.ascii "and" "cc" "" " r3, r" "3" ", r" "2" ", asr #5"
^
The text was updated successfully, but these errors were encountered: