Skip to content

Commit 018b6e8

Browse files
committed
Implement multithreading in voxel-mesh manager, and cleanup.
- Disable thin LTO due to rust-lang/rust#81408 - Pin shaderc to 0.7.3 due to linker errors with newer version. - Update dependencies.
1 parent a3a2788 commit 018b6e8

File tree

8 files changed

+157
-106
lines changed

8 files changed

+157
-106
lines changed

.run/FB voxel_meshing -- Standalone-MC.run.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<component name="ProjectRunConfigurationManager">
22
<configuration default="false" name="FB voxel_meshing -- Standalone-MC" type="CargoCommandRunConfiguration" factoryName="Cargo Command">
3-
<option name="command" value="bench --package voxel_meshing --profile fastbench -- Standalone-MC" />
3+
<option name="command" value="bench --package voxel_meshing --profile=fastbench -- Standalone-MC" />
44
<option name="workingDirectory" value="file://$PROJECT_DIR$" />
55
<option name="channel" value="DEFAULT" />
66
<option name="requiredFeatures" value="false" />

.run/FB voxel_meshing -- Standalone-Sphere.run.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<component name="ProjectRunConfigurationManager">
22
<configuration default="false" name="FB voxel_meshing -- Standalone-Sphere" type="CargoCommandRunConfiguration" factoryName="Cargo Command">
3-
<option name="command" value="bench --package voxel_meshing --profile fastbench -- Standalone-Sphere" />
3+
<option name="command" value="bench --package voxel_meshing --profile=fastbench -- Standalone-Sphere" />
44
<option name="workingDirectory" value="file://$PROJECT_DIR$" />
55
<option name="channel" value="DEFAULT" />
66
<option name="requiredFeatures" value="false" />

.run/RR voxel_meshing.run.xml

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

Cargo.lock

Lines changed: 42 additions & 47 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 25 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ default-members = [
1212
]
1313
resolver = "2"
1414

15-
# Development profile: no debug information, some optimisations.
15+
16+
# Development profile: no debug information, some optimisations. Very low compile-time.
1617
[profile.dev]
1718
opt-level = 2
1819
debug = false
@@ -29,11 +30,12 @@ overflow-checks = true
2930
debug-assertions = true
3031
incremental = true
3132

32-
# Testing: same as development profile.
33+
# Testing: same as development profile. Very low compile-time.
3334
[profile.test]
3435
inherits = "dev"
3536

36-
# Debug profile: full debug information, no optimisations.
37+
38+
# Debug profile: full debug information, no optimisations. Low compile-time.
3739
[profile.dbg]
3840
inherits = "dev"
3941
opt-level = 0
@@ -51,7 +53,8 @@ overflow-checks = true
5153
debug-assertions = true
5254
incremental = true
5355

54-
# Release profile: full optimisations, including full LTO.
56+
57+
# Release profile: full optimisations, including full LTO. High compile-time.
5558
[profile.release]
5659
opt-level = 3
5760
debug = false
@@ -60,18 +63,29 @@ debug-assertions = false
6063
lto = true
6164
panic = "abort"
6265

63-
# Benchmarking profile: full optimisations, including full LTO.
66+
# Fast iteration release profile: full optimisations, but without LTO. Medium compile-time.
67+
[profile.fastrelease]
68+
inherits = "release"
69+
incremental = true
70+
codegen-units = 256
71+
lto = false
72+
73+
74+
# Benchmarking profile = release. High compile-time.
6475
[profile.bench]
6576
inherits = "release"
6677

67-
# Fast benchmarking profile: full optimisations, but with thin LTO and incrementality enabled.
78+
# Fast iteration benchmarking profile = fastrelease. Medium compile-time
6879
[profile.fastbench]
69-
inherits = "release"
70-
incremental = true
71-
codegen-units = 256
72-
lto = "thin"
80+
inherits = "fastrelease"
7381

74-
# Performance profiling profile: full debug information, full optimisations.
82+
83+
# Performance profiling profile = release + debug. High compile-time.
7584
[profile.profile]
7685
inherits = "release"
7786
debug = true
87+
88+
# Fast iteration performance profiling profile = fastrelease + debug. Medium compile-time
89+
[profile.fastprofile]
90+
inherits = "fastrelease"
91+
debug = true

core/gfxc/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,6 @@ edition = "2021"
66
publish = false
77

88
[dependencies]
9-
shaderc = "0.7"
9+
shaderc = "=0.7.3"
10+
shaderc-sys = "=0.7.3"
1011
walkdir = "2.3"

0 commit comments

Comments
 (0)