Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Event Timeline
This is patch [1/2], it is just tests.
Note: This is a follow up to https://reviews.llvm.org/D140645 and is splitting up the reviews for the tests and code.
Thanks for the patch. I suggest we only test either BMI or BMI2. The difference between BMI and BMI2 is not what we care about in these patches.
Do you mean test: [neither, bmi1 + bmi2]
or do you mean test [neither]?
If the former already done:
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py ; RUN: llc -mtriple=i686-unknown-linux-gnu -mattr=-bmi,-bmi2 < %s | FileCheck %s --check-prefixes=X86-NOBMI2 ; RUN: llc -mtriple=i686-unknown-linux-gnu -mattr=+bmi,+bmi2 < %s | FileCheck %s --check-prefixes=X86-BMI2 ; RUN: llc -mtriple=x86_64-unknown-linux-gnu -mattr=-bmi,-bmi2 < %s | FileCheck %s --check-prefixes=X64-NOBMI2 ; RUN: llc -mtriple=x86_64-unknown-linux-gnu -mattr=+bmi,+bmi2 < %s | FileCheck %s --check-prefixes=X64-BMI2 ...
I mean
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py ; RUN: llc -mtriple=i686-unknown-linux-gnu -mattr=+bmi2 < %s | FileCheck %s --check-prefixes=X86 ; RUN: llc -mtriple=x86_64-unknown-linux-gnu -mattr=+bmi2 < %s | FileCheck %s --check-prefixes=X64
Or
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py ; RUN: llc -mtriple=i686-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=X86 ; RUN: llc -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s --check-prefixes=X64
llvm/test/CodeGen/X86/atomic-rm-bit-test.ll | ||
---|---|---|
7393–7429 | I think we never have a chance to optimize 64-bit operations on 32-bits, right? Should we move these 64-bit tests to another file and only leave a single run ; RUN: llc -mtriple=x86_64-unknown-linux-gnu < %s | FileCheck %s |
llvm/test/CodeGen/X86/atomic-rm-bit-test.ll | ||
---|---|---|
7393–7429 |
We get it something i.e: define zeroext i16 @atomic_shl1_or_16_const_val(ptr %v) nounwind { ; X86-LABEL: atomic_shl1_or_16_const_val: ; X86: # %bb.0: # %entry ; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx ; X86-NEXT: xorl %eax, %eax ; X86-NEXT: lock btsw $4, (%ecx) ; X86-NEXT: setb %al ; X86-NEXT: shll $4, %eax ; X86-NEXT: # kill: def $ax killed $ax killed $eax ; X86-NEXT: retl |
llvm/test/CodeGen/X86/atomic-rm-bit-test.ll | ||
---|---|---|
7393–7429 | I mean just put these define i64 @...64... into another file and only run for 64-bit. |
llvm/test/CodeGen/X86/atomic-rm-bit-test.ll | ||
---|---|---|
7393–7429 | Yes you probably want 2 files: atomic-rm-bit-test.ll (non-i64 tests tested on 32/64 triples) and atomic-rm-bit-test-x86_64.ll (i64 tests tested just on 64 triples). |
LGTM. Do you want me to commit it for you?
llvm/test/CodeGen/X86/atomic-rm-bit-test-64.ll | ||
---|---|---|
2 | We don't need prefix for single RUN. I can update it for you. |
We don't need prefix for single RUN. I can update it for you.