[llvm] b30bc8c - RISCV: simplify a test case for RISCV (NFCI)

Saleem Abdulrasool via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 18 08:21:56 PDT 2021


Author: Saleem Abdulrasool
Date: 2021-06-18T08:19:16-07:00
New Revision: b30bc8cc5d51a0c61651bafd977eb6b1729ca471

URL: https://github.com/llvm/llvm-project/commit/b30bc8cc5d51a0c61651bafd977eb6b1729ca471
DIFF: https://github.com/llvm/llvm-project/commit/b30bc8cc5d51a0c61651bafd977eb6b1729ca471.diff

LOG: RISCV: simplify a test case for RISCV (NFCI)

The output of the object file is unimportant and entirely discarded.
Simply redirect the output to `/dev/null` or `NUL` as the case may be.
Additionally, the space between the labels is unimportant.  There is no
need to add space between the labels.  Two labels at the same address
are sufficient to generate the difference expression and should still
test the same behaviour.

Added: 
    

Modified: 
    llvm/test/MC/RISCV/hilo-constaddr-expr.s

Removed: 
    


################################################################################
diff  --git a/llvm/test/MC/RISCV/hilo-constaddr-expr.s b/llvm/test/MC/RISCV/hilo-constaddr-expr.s
index af47985cde7c1..8dc38702a2472 100644
--- a/llvm/test/MC/RISCV/hilo-constaddr-expr.s
+++ b/llvm/test/MC/RISCV/hilo-constaddr-expr.s
@@ -1,13 +1,11 @@
-# RUN: not llvm-mc -filetype=obj -triple=riscv32 -mattr=+relax %s 2>&1 | FileCheck %s
-# RUN: not llvm-mc -filetype=obj -triple=riscv32 -mattr=-relax %s 2>&1 | FileCheck %s
+# RUN: not llvm-mc -filetype=obj -triple=riscv32 -mattr=+relax %s -o /dev/null 2>&1 | FileCheck %s
+# RUN: not llvm-mc -filetype=obj -triple=riscv32 -mattr=-relax %s -o /dev/null 2>&1 | FileCheck %s
 
 # Check the assembler rejects hi and lo expressions with constant expressions
 # involving labels when 
diff  expressions are emitted as relocation pairs.
 # Test case derived from test/MC/Mips/hilo-addressing.s
 
 tmp1:
-  # Emit zeros so that 
diff erence between tmp1 and tmp3 is 0x30124 bytes.
-  .fill 0x30124-8
 tmp2:
 # CHECK: :[[#@LINE+1]]:[[#]]: error: expected relocatable expression
   lui t0, %hi(tmp3-tmp1)


        


More information about the llvm-commits mailing list