llvm-project/bolt/test/X86/icf-jump-tables.test
Connie 887f7002b6
[NFC][bolt][test] Change '|&' to '2>&1 |' for lit internal shell support (#102402)
This patches changes all references to '|&' in bolt tests to instead use
the '2>&1 |' syntax for better consistency across testing and so that
lit's internal shell can be used to run these tests. This addresses a
suggestion made in the comments of this RFC:
https://discourse.llvm.org/t/rfc-enabling-the-lit-internal-shell-by-default/80179.

Fixes https://github.com/llvm/llvm-project/issues/102388
2024-08-12 17:18:17 -07:00

14 lines
501 B
Plaintext

## Check that BOLT folds functions with jump tables and does not report
## undefined symbols.
# REQUIRES: system-linux
# RUN: %clang %cflags -O1 -g %p/../Inputs/icf-jump-tables.c -o %t.exe -Wl,-q
# RUN: llvm-bolt %t.exe --icf -o %t.bolt 2>&1 | FileCheck %s
## Check that BOLT successfully folded a function with jump table:
# CHECK: ICF folded {{.*}}. {{[^0]}} functions had jump tables.
## Check that no relocations against undefined symbols were emitted:
# CHECK-NOT: Undefined temporary symbol