Skip to content

Commit a689968

Browse files
[𝘀𝗽𝗿] changes to main this commit is based on
Created using spr 1.3.6 [skip ci]
1 parent b869dfc commit a689968

13 files changed

+85
-47
lines changed

llvm/test/MC/COFF/stdin.s

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
// REQUIRES: shell
2-
// RUN: ( echo "test"; llvm-mc -filetype=obj -triple i686-pc-win32 %s ) > %t
3-
1+
// RUN: bash -c '(echo "test"; llvm-mc -filetype=obj -triple i686-pc-win32 %s ) > %t'

llvm/test/Other/pipefail.txt

Lines changed: 0 additions & 2 deletions
This file was deleted.

llvm/test/tools/llvm-cgdata/merge-combined-funcmap-hashtree.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Test merge a single object file having both __llvm_outline and __llvm_merge into a cgdata.
@@ -8,15 +8,19 @@ RUN: split-file %s %t
88

99
# Synthesize raw hashtree bytes without the header (32 byte) from the indexed cgdata.
1010
RUN: llvm-cgdata --convert --format binary %t/raw-hashtree.cgtext -o %t/raw-hashtree.cgdata
11-
RUN: od -t x1 -j 32 -An %t/raw-hashtree.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-hashtree-bytes.txt
11+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-hashtree-sed.txt
12+
RUN: od -t x1 -j 32 -An %t/raw-hashtree.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-hashtree-sed.txt
13+
RUN: echo "/g" >> %t/raw-hashtree-sed.txt
1214

1315
# Synthesize raw funcmap bytes without the header (32 byte) from the indexed cgdata.
1416
RUN: llvm-cgdata --convert --format binary %t/raw-funcmap.cgtext -o %t/raw-funcmap.cgdata
15-
RUN: od -t x1 -j 32 -An %t/raw-funcmap.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-funcmap-bytes.txt
17+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-funcmap-sed.txt
18+
RUN: od -t x1 -j 32 -An %t/raw-funcmap.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-funcmap-sed.txt
19+
RUN: echo "/g" >> %t/raw-funcmap-sed.txt
1620

1721
# Synthesize a bitcode file by creating two sections for the hash tree and the function map, respectively.
18-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-hashtree-bytes.txt)/g" %t/merge-both-template.ll > %t/merge-both-hashtree-template.ll
19-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-funcmap-bytes.txt)/g" %t/merge-both-hashtree-template.ll > %t/merge-both-hashtree-funcmap.ll
22+
RUN: sed -f %t/raw-hashtree-sed.txt %t/merge-both-template.ll > %t/merge-both-hashtree-template.ll
23+
RUN: sed -f %t/raw-funcmap-sed.txt %t/merge-both-hashtree-template.ll > %t/merge-both-hashtree-funcmap.ll
2024

2125
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-both-hashtree-funcmap.ll -o %t/merge-both-hashtree-funcmap.o
2226

llvm/test/tools/llvm-cgdata/merge-funcmap-archive.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Merge an archive that has two object files having cgdata (__llvm_merge)
@@ -7,14 +7,18 @@ RUN: split-file %s %t
77

88
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
99
RUN: llvm-cgdata --convert --format binary %t/raw-1.cgtext -o %t/raw-1.cgdata
10-
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-1-bytes.txt
11-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-1-bytes.txt)/g" %t/merge-1-template.ll > %t/merge-1.ll
10+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-1-sed.txt
11+
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-1-sed.txt
12+
RUN: echo "/g" >> %t/raw-1-sed.txt
13+
RUN: sed -f %t/raw-1-sed.txt %t/merge-1-template.ll > %t/merge-1.ll
1214
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-1.ll -o %t/merge-1.o
1315

1416
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
1517
RUN: llvm-cgdata --convert --format binary %t/raw-2.cgtext -o %t/raw-2.cgdata
16-
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-2-bytes.txt
17-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-2-bytes.txt)/g" %t/merge-2-template.ll > %t/merge-2.ll
18+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-2-sed.txt
19+
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-2-sed.txt
20+
RUN: echo "/g" >> %t/raw-2-sed.txt
21+
RUN: sed -f %t/raw-2-sed.txt %t/merge-2-template.ll > %t/merge-2.ll
1822
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-2.ll -o %t/merge-2.o
1923

2024
# Make an archive from two object files

llvm/test/tools/llvm-cgdata/merge-funcmap-concat.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Merge a binary file (e.g., a linked executable) having concatenated cgdata (__llvm_merge)
@@ -8,11 +8,15 @@ RUN: split-file %s %t
88
# Synthesize two sets of raw cgdata without the header (32 byte) from the indexed cgdata.
99
# Concatenate them in merge-concat.ll
1010
RUN: llvm-cgdata --convert --format binary %t/raw-1.cgtext -o %t/raw-1.cgdata
11-
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-1-bytes.txt
12-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-1-bytes.txt)/g" %t/merge-concat-template.ll > %t/merge-concat-template-2.ll
11+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-1-sed.txt
12+
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-1-sed.txt
13+
RUN: echo "/g" >> %t/raw-1-sed.txt
14+
RUN: sed -f %t/raw-1-sed.txt %t/merge-concat-template.ll > %t/merge-concat-template-2.ll
1315
RUN: llvm-cgdata --convert --format binary %t/raw-2.cgtext -o %t/raw-2.cgdata
14-
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-2-bytes.txt
15-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-2-bytes.txt)/g" %t/merge-concat-template-2.ll > %t/merge-concat.ll
16+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-2-sed.txt
17+
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-2-sed.txt
18+
RUN: echo "/g" >> %t/raw-2-sed.txt
19+
RUN: sed -f %t/raw-2-sed.txt %t/merge-concat-template-2.ll > %t/merge-concat.ll
1620

1721
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-concat.ll -o %t/merge-concat.o
1822
RUN: llvm-cgdata --merge --skip-trim %t/merge-concat.o -o %t/merge-concat.cgdata

llvm/test/tools/llvm-cgdata/merge-funcmap-double.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Merge two object files having cgdata (__llvm_merge)
@@ -7,14 +7,18 @@ RUN: split-file %s %t
77

88
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
99
RUN: llvm-cgdata --convert --format binary %t/raw-1.cgtext -o %t/raw-1.cgdata
10-
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-1-bytes.txt
11-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-1-bytes.txt)/g" %t/merge-1-template.ll > %t/merge-1.ll
10+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-1-sed.txt
11+
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-1-sed.txt
12+
RUN: echo "/g" >> %t/raw-1-sed.txt
13+
RUN: sed -f %t/raw-1-sed.txt %t/merge-1-template.ll > %t/merge-1.ll
1214
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-1.ll -o %t/merge-1.o
1315

1416
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
1517
RUN: llvm-cgdata --convert --format binary %t/raw-2.cgtext -o %t/raw-2.cgdata
16-
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-2-bytes.txt
17-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-2-bytes.txt)/g" %t/merge-2-template.ll > %t/merge-2.ll
18+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-2-sed.txt
19+
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-2-sed.txt
20+
RUN: echo "/g" >> %t/raw-2-sed.txt
21+
RUN: sed -f %t/raw-2-sed.txt %t/merge-2-template.ll > %t/merge-2.ll
1822
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-2.ll -o %t/merge-2.o
1923

2024
# Merge two object files into the codegen data file.

llvm/test/tools/llvm-cgdata/merge-funcmap-single.test

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Test merge a single object file into a cgdata
@@ -7,9 +7,11 @@ RUN: split-file %s %t
77

88
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
99
RUN: llvm-cgdata --convert --format binary %t/raw-single.cgtext -o %t/raw-single.cgdata
10-
RUN: od -t x1 -j 32 -An %t/raw-single.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-single-bytes.txt
10+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-single-sed.txt
11+
RUN: od -t x1 -j 32 -An %t/raw-single.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-single-sed.txt
12+
RUN: echo "/g" >> %t/raw-single-sed.txt
1113

12-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-single-bytes.txt)/g" %t/merge-single-template.ll > %t/merge-single.ll
14+
RUN: sed -f %t/raw-single-sed.txt %t/merge-single-template.ll > %t/merge-single.ll
1315
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-single.ll -o %t/merge-single.o
1416

1517
# Merge an object file having cgdata (__llvm_merge)

llvm/test/tools/llvm-cgdata/merge-hashtree-archive.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Merge an archive that has two object files having cgdata (__llvm_outline)
@@ -7,14 +7,18 @@ RUN: split-file %s %t
77

88
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
99
RUN: llvm-cgdata --convert --format binary %t/raw-1.cgtext -o %t/raw-1.cgdata
10-
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-1-bytes.txt
11-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-1-bytes.txt)/g" %t/merge-1-template.ll > %t/merge-1.ll
10+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-1-sed.txt
11+
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-1-sed.txt
12+
RUN: echo "/g" >> %t/raw-1-sed.txt
13+
RUN: sed -f %t/raw-1-sed.txt %t/merge-1-template.ll > %t/merge-1.ll
1214
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-1.ll -o %t/merge-1.o
1315

1416
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
1517
RUN: llvm-cgdata --convert --format binary %t/raw-2.cgtext -o %t/raw-2.cgdata
16-
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-2-bytes.txt
17-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-2-bytes.txt)/g" %t/merge-2-template.ll > %t/merge-2.ll
18+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-2-sed.txt
19+
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-2-sed.txt
20+
RUN: echo "/g" >> %t/raw-2-sed.txt
21+
RUN: sed -f %t/raw-2-sed.txt %t/merge-2-template.ll > %t/merge-2.ll
1822
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-2.ll -o %t/merge-2.o
1923

2024
# Make an archive from two object files

llvm/test/tools/llvm-cgdata/merge-hashtree-concat.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Merge a binary file (e.g., a linked executable) having concatenated cgdata (__llvm_outline)
@@ -8,11 +8,15 @@ RUN: split-file %s %t
88
# Synthesize two sets of raw cgdata without the header (32 byte) from the indexed cgdata.
99
# Concatenate them in merge-concat.ll
1010
RUN: llvm-cgdata --convert --format binary %t/raw-1.cgtext -o %t/raw-1.cgdata
11-
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-1-bytes.txt
12-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-1-bytes.txt)/g" %t/merge-concat-template.ll > %t/merge-concat-template-2.ll
11+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-1-sed.txt
12+
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-1-sed.txt
13+
RUN: echo "/g" >> %t/raw-1-sed.txt
14+
RUN: sed -f %t/raw-1-sed.txt %t/merge-concat-template.ll > %t/merge-concat-template-2.ll
1315
RUN: llvm-cgdata --convert --format binary %t/raw-2.cgtext -o %t/raw-2.cgdata
14-
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-2-bytes.txt
15-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-2-bytes.txt)/g" %t/merge-concat-template-2.ll > %t/merge-concat.ll
16+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-2-sed.txt
17+
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-2-sed.txt
18+
RUN: echo "/g" >> %t/raw-2-sed.txt
19+
RUN: sed -f %t/raw-2-sed.txt %t/merge-concat-template-2.ll > %t/merge-concat.ll
1620

1721
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-concat.ll -o %t/merge-concat.o
1822
RUN: llvm-cgdata --merge %t/merge-concat.o -o %t/merge-concat.cgdata

llvm/test/tools/llvm-cgdata/merge-hashtree-double.test

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# REQUIRES: shell, aarch64-registered-target
1+
# REQUIRES: aarch64-registered-target
22
# UNSUPPORTED: system-windows
33

44
# Merge two object files having cgdata (__llvm_outline)
@@ -7,14 +7,18 @@ RUN: split-file %s %t
77

88
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
99
RUN: llvm-cgdata --convert --format binary %t/raw-1.cgtext -o %t/raw-1.cgdata
10-
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-1-bytes.txt
11-
RUN: sed "s/<RAW_1_BYTES>/$(cat %t/raw-1-bytes.txt)/g" %t/merge-1-template.ll > %t/merge-1.ll
10+
RUN: echo -n "s/<RAW_1_BYTES>/" > %t/raw-1-sed.txt
11+
RUN: od -t x1 -j 32 -An %t/raw-1.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-1-sed.txt
12+
RUN: echo "/g" >> %t/raw-1-sed.txt
13+
RUN: sed -f %t/raw-1-sed.txt %t/merge-1-template.ll > %t/merge-1.ll
1214
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-1.ll -o %t/merge-1.o
1315

1416
# Synthesize raw cgdata without the header (32 byte) from the indexed cgdata.
1517
RUN: llvm-cgdata --convert --format binary %t/raw-2.cgtext -o %t/raw-2.cgdata
16-
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' > %t/raw-2-bytes.txt
17-
RUN: sed "s/<RAW_2_BYTES>/$(cat %t/raw-2-bytes.txt)/g" %t/merge-2-template.ll > %t/merge-2.ll
18+
RUN: echo -n "s/<RAW_2_BYTES>/" > %t/raw-2-sed.txt
19+
RUN: od -t x1 -j 32 -An %t/raw-2.cgdata | tr -d '\n\r\t' | sed 's/[ ]*$//' | sed 's/[ ][ ]*/\\\\/g' >> %t/raw-2-sed.txt
20+
RUN: echo "/g" >> %t/raw-2-sed.txt
21+
RUN: sed -f %t/raw-2-sed.txt %t/merge-2-template.ll > %t/merge-2.ll
1822
RUN: llc -filetype=obj -mtriple arm64-apple-darwin %t/merge-2.ll -o %t/merge-2.o
1923

2024
# Merge two object files into the codegen data file.

0 commit comments

Comments
 (0)