Skip to content

Commit 5bf0b3c

Browse files
authored
Merge branch 'rust-lang:master' into master
2 parents 17e3297 + e69f125 commit 5bf0b3c

File tree

13 files changed

+21
-39
lines changed

13 files changed

+21
-39
lines changed

.github/workflows/ci.yml

+3-6
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,7 @@ jobs:
6666
- name: Build
6767
run: |
6868
./y.sh prepare --only-libcore
69-
# TODO: remove --features master when it is back to the default.
70-
./y.sh build --features master
71-
# TODO: remove --features master when it is back to the default.
69+
./y.sh build
7270
7371
- name: Set env (part 2)
7472
run: |
@@ -78,7 +76,7 @@ jobs:
7876
7977
- name: Build (part 2)
8078
run: |
81-
cargo test --features master
79+
cargo test
8280
./y.sh clean all
8381
8482
- name: Prepare dependencies
@@ -92,8 +90,7 @@ jobs:
9290

9391
- name: Run tests
9492
run: |
95-
# TODO: remove --features master when it is back to the default.
96-
./y.sh test --features master --release --clean --build-sysroot ${{ matrix.commands }}
93+
./y.sh test --release --clean --build-sysroot ${{ matrix.commands }}
9794
9895
duplicates:
9996
runs-on: ubuntu-latest

.github/workflows/failures.yml

+1-4
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,11 @@ jobs:
2121
libgccjit_version:
2222
- gcc: "libgccjit.so"
2323
artifacts_branch: "master"
24-
# TODO: switch back to --no-default-features in the case of libgccjit 12 when the default is to enable
25-
# master again.
26-
extra: "--features master"
2724
- gcc: "libgccjit_without_int128.so"
2825
artifacts_branch: "master-without-128bit-integers"
29-
extra: "--features master"
3026
- gcc: "libgccjit12.so"
3127
artifacts_branch: "gcc12"
28+
extra: "--no-default-features"
3229
# FIXME(antoyo): we need to set GCC_EXEC_PREFIX so that the linker can find the linker plugin.
3330
# Not sure why it's not found otherwise.
3431
env_extra: "TEST_FLAGS='-Cpanic=abort -Zpanic-abort-tests' GCC_EXEC_PREFIX=/usr/lib/gcc/"

.github/workflows/m68k.yml

+3-6
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,8 @@ jobs:
9191
- name: Build
9292
run: |
9393
./y.sh prepare --only-libcore --cross
94-
# TODO: remove --features master when it is back to the default.
95-
./y.sh build --target-triple m68k-unknown-linux-gnu --features master
96-
# TODO: remove --features master when it is back to the default.
97-
CG_GCC_TEST_TARGET=m68k-unknown-linux-gnu cargo test --features master
94+
./y.sh build --target-triple m68k-unknown-linux-gnu
95+
CG_GCC_TEST_TARGET=m68k-unknown-linux-gnu cargo test
9896
./y.sh clean all
9997
10098
- name: Prepare dependencies
@@ -108,5 +106,4 @@ jobs:
108106

109107
- name: Run tests
110108
run: |
111-
# TODO: remove --features master when it is back to the default.
112-
./y.sh test --release --features master --clean --build-sysroot ${{ matrix.commands }}
109+
./y.sh test --release --clean --build-sysroot ${{ matrix.commands }}

.github/workflows/release.yml

+3-6
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,8 @@ jobs:
5353
- name: Build
5454
run: |
5555
./y.sh prepare --only-libcore
56-
# TODO: remove --features master when it is back to the default.
57-
EMBED_LTO_BITCODE=1 ./y.sh build --release --release-sysroot --features master
58-
# TODO: remove --features master when it is back to the default.
59-
cargo test --features master
56+
EMBED_LTO_BITCODE=1 ./y.sh build --release --release-sysroot
57+
cargo test
6058
./y.sh clean all
6159
6260
- name: Prepare dependencies
@@ -72,5 +70,4 @@ jobs:
7270

7371
- name: Run tests
7472
run: |
75-
# TODO: remove --features master when it is back to the default.
76-
EMBED_LTO_BITCODE=1 ./y.sh test --release --clean --release-sysroot --build-sysroot ${{ matrix.commands }} --features master
73+
EMBED_LTO_BITCODE=1 ./y.sh test --release --clean --release-sysroot --build-sysroot ${{ matrix.commands }}

.github/workflows/stdarch.yml

+3-6
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,8 @@ jobs:
6767
- name: Build
6868
run: |
6969
./y.sh prepare --only-libcore
70-
# TODO: remove `--features master` when it is back to the default.
71-
./y.sh build --release --release-sysroot --features master
72-
# TODO: remove --features master when it is back to the default.
73-
cargo test --features master
70+
./y.sh build --release --release-sysroot
71+
cargo test
7472
7573
- name: Clean
7674
if: ${{ !matrix.cargo_runner }}
@@ -86,8 +84,7 @@ jobs:
8684
- name: Run tests
8785
if: ${{ !matrix.cargo_runner }}
8886
run: |
89-
# TODO: remove `--features master` when it is back to the default.
90-
./y.sh test --release --clean --release-sysroot --build-sysroot --mini-tests --std-tests --test-libcore --features master
87+
./y.sh test --release --clean --release-sysroot --build-sysroot --mini-tests --std-tests --test-libcore
9188
9289
- name: Run stdarch tests
9390
if: ${{ !matrix.cargo_runner }}

.gitignore

-6
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,10 @@ perf.data.old
1010
/build_sysroot/sysroot_src
1111
/build_sysroot/Cargo.lock
1212
/build_sysroot/test_target/Cargo.lock
13-
/rust
14-
/simple-raytracer
15-
/regex
16-
/rand
1713
gimple*
1814
*asm
1915
res
2016
test-backend
21-
gcc_path
22-
cross_gcc_path
2317
projects
2418
benchmarks
2519
tools/llvm-project

.ignore

+1
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@
88
!*gimple*
99
!*asm*
1010
!.github
11+
!config.toml

Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ harness = false
1919

2020
[features]
2121
master = ["gccjit/master"]
22+
default = ["master"]
2223

2324
[dependencies]
2425
gccjit = { git = "https://github.com/antoyo/gccjit.rs" }

Readme.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -69,13 +69,13 @@ Then you can run commands like this:
6969

7070
```bash
7171
$ ./y.sh prepare # download and patch sysroot src and install hyperfine for benchmarking
72-
$ ./y.sh build --release --features master
72+
$ ./y.sh build --release
7373
```
7474

7575
To run the tests:
7676

7777
```bash
78-
$ ./y.sh test --release --features master
78+
$ ./y.sh test --release
7979
```
8080

8181
## Usage

build_system/src/prepare.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ fn prepare_libcore(
9595
)?;
9696
if cross_compile {
9797
walk_dir(
98-
"cross_patches",
98+
"patches/cross_patches",
9999
|_| Ok(()),
100100
|file_path: &Path| {
101101
patches.push(file_path.to_path_buf());
@@ -161,7 +161,7 @@ where
161161
run_command(&[&"git", &"checkout", &checkout_commit], Some(&repo_path))?;
162162
let filter = format!("-{}-", clone_result.repo_name);
163163
walk_dir(
164-
"crate_patches",
164+
"patches/crate_patches",
165165
|_| Ok(()),
166166
|file_path| {
167167
let patch = file_path.as_os_str().to_str().unwrap();

src/back/write.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,8 @@ pub(crate) unsafe fn codegen(cgcx: &CodegenContext<GccCodegenBackend>, diag_hand
7070
}
7171

7272
if config.emit_ir {
73-
unimplemented!();
73+
let out = cgcx.output_filenames.temp_path(OutputType::LlvmAssembly, module_name);
74+
std::fs::write(out, "").expect("write file");
7475
}
7576

7677
if config.emit_asm {

0 commit comments

Comments
 (0)