upgrade inkwell

This commit is contained in:
Folkert 2020-11-17 01:58:30 +01:00
parent 0fd184392f
commit 8528e5affb
7 changed files with 26 additions and 16 deletions

14
Cargo.lock generated
View file

@ -1195,25 +1195,25 @@ dependencies = [
[[package]] [[package]]
name = "inkwell" name = "inkwell"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/rtfeldman/inkwell?tag=llvm10-0.release2#d0a1ce5e678cf0f0e62b757760d1019301c603c9" source = "git+https://github.com/rtfeldman/inkwell?tag=llvm10-0.release3#57e9f00d98fc99486e737c314e56a59498c5dbbb"
dependencies = [ dependencies = [
"either", "either",
"inkwell_internals", "inkwell_internals",
"libc", "libc",
"llvm-sys", "llvm-sys",
"once_cell", "once_cell",
"parking_lot 0.10.2", "parking_lot 0.11.0",
"regex", "regex",
] ]
[[package]] [[package]]
name = "inkwell_internals" name = "inkwell_internals"
version = "0.1.0" version = "0.2.0"
source = "git+https://github.com/rtfeldman/inkwell?tag=llvm10-0.release2#d0a1ce5e678cf0f0e62b757760d1019301c603c9" source = "git+https://github.com/rtfeldman/inkwell?tag=llvm10-0.release3#57e9f00d98fc99486e737c314e56a59498c5dbbb"
dependencies = [ dependencies = [
"proc-macro2 0.4.30", "proc-macro2 1.0.21",
"quote 0.6.13", "quote 1.0.7",
"syn 0.15.44", "syn 1.0.40",
] ]
[[package]] [[package]]

View file

@ -77,7 +77,7 @@ libloading = "0.6"
# commit of TheDan64/inkwell, push a new tag which points to the latest commit, # commit of TheDan64/inkwell, push a new tag which points to the latest commit,
# change the tag value in this Cargo.toml to point to that tag, and `cargo update`. # change the tag value in this Cargo.toml to point to that tag, and `cargo update`.
# This way, GitHub Actions works and nobody's builds get broken. # This way, GitHub Actions works and nobody's builds get broken.
inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release2" } inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release3" }
target-lexicon = "0.10" target-lexicon = "0.10"
[dev-dependencies] [dev-dependencies]

View file

@ -45,7 +45,7 @@ tempfile = "3.1.0"
# commit of TheDan64/inkwell, push a new tag which points to the latest commit, # commit of TheDan64/inkwell, push a new tag which points to the latest commit,
# change the tag value in this Cargo.toml to point to that tag, and `cargo update`. # change the tag value in this Cargo.toml to point to that tag, and `cargo update`.
# This way, GitHub Actions works and nobody's builds get broken. # This way, GitHub Actions works and nobody's builds get broken.
inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release2" } inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release3" }
target-lexicon = "0.10" target-lexicon = "0.10"
[dev-dependencies] [dev-dependencies]

View file

@ -39,7 +39,7 @@ either = "1.6.1"
# commit of TheDan64/inkwell, push a new tag which points to the latest commit, # commit of TheDan64/inkwell, push a new tag which points to the latest commit,
# change the tag value in this Cargo.toml to point to that tag, and `cargo update`. # change the tag value in this Cargo.toml to point to that tag, and `cargo update`.
# This way, GitHub Actions works and nobody's builds get broken. # This way, GitHub Actions works and nobody's builds get broken.
inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release2" } inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release3" }
target-lexicon = "0.10" target-lexicon = "0.10"
libloading = "0.6" libloading = "0.6"

View file

@ -185,7 +185,9 @@ pub fn list_prepend<'a, 'ctx, 'env>(
// one we just malloc'd. // one we just malloc'd.
// //
// TODO how do we decide when to do the small memcpy vs the normal one? // TODO how do we decide when to do the small memcpy vs the normal one?
builder.build_memcpy(index_1_ptr, ptr_bytes, list_ptr, ptr_bytes, list_size); builder
.build_memcpy(index_1_ptr, ptr_bytes, list_ptr, ptr_bytes, list_size)
.unwrap();
} else { } else {
panic!("TODO Cranelift currently only knows how to clone list elements that are Copy."); panic!("TODO Cranelift currently only knows how to clone list elements that are Copy.");
} }
@ -626,7 +628,9 @@ pub fn list_append<'a, 'ctx, 'env>(
// one we just malloc'd. // one we just malloc'd.
// //
// TODO how do we decide when to do the small memcpy vs the normal one? // TODO how do we decide when to do the small memcpy vs the normal one?
builder.build_memcpy(clone_ptr, ptr_bytes, list_ptr, ptr_bytes, list_size); builder
.build_memcpy(clone_ptr, ptr_bytes, list_ptr, ptr_bytes, list_size)
.unwrap();
} else { } else {
panic!("TODO Cranelift currently only knows how to clone list elements that are Copy."); panic!("TODO Cranelift currently only knows how to clone list elements that are Copy.");
} }
@ -1816,7 +1820,9 @@ pub fn clone_nonempty_list<'a, 'ctx, 'env>(
// one we just malloc'd. // one we just malloc'd.
// //
// TODO how do we decide when to do the small memcpy vs the normal one? // TODO how do we decide when to do the small memcpy vs the normal one?
builder.build_memcpy(clone_ptr, ptr_bytes, elems_ptr, ptr_bytes, size); builder
.build_memcpy(clone_ptr, ptr_bytes, elems_ptr, ptr_bytes, size)
.unwrap();
} else { } else {
panic!("TODO Cranelift currently only knows how to clone list elements that are Copy."); panic!("TODO Cranelift currently only knows how to clone list elements that are Copy.");
} }
@ -1872,7 +1878,9 @@ pub fn clone_list<'a, 'ctx, 'env>(
); );
// copy old elements in // copy old elements in
builder.build_memcpy(new_ptr, ptr_bytes, old_ptr, ptr_bytes, bytes); builder
.build_memcpy(new_ptr, ptr_bytes, old_ptr, ptr_bytes, bytes)
.unwrap();
new_ptr new_ptr
} }

View file

@ -537,7 +537,9 @@ fn clone_nonempty_str<'a, 'ctx, 'env>(
// Copy the bytes from the original array into the new // Copy the bytes from the original array into the new
// one we just malloc'd. // one we just malloc'd.
builder.build_memcpy(clone_ptr, ptr_bytes, bytes_ptr, ptr_bytes, len); builder
.build_memcpy(clone_ptr, ptr_bytes, bytes_ptr, ptr_bytes, len)
.unwrap();
// Create a fresh wrapper struct for the newly populated array // Create a fresh wrapper struct for the newly populated array
let struct_type = collection(ctx, env.ptr_bytes); let struct_type = collection(ctx, env.ptr_bytes);

View file

@ -47,7 +47,7 @@ tokio = { version = "0.2", features = ["blocking", "fs", "sync", "rt-threaded",
# commit of TheDan64/inkwell, push a new tag which points to the latest commit, # commit of TheDan64/inkwell, push a new tag which points to the latest commit,
# change the tag value in this Cargo.toml to point to that tag, and `cargo update`. # change the tag value in this Cargo.toml to point to that tag, and `cargo update`.
# This way, GitHub Actions works and nobody's builds get broken. # This way, GitHub Actions works and nobody's builds get broken.
inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release2" } inkwell = { git = "https://github.com/rtfeldman/inkwell", tag = "llvm10-0.release3" }
target-lexicon = "0.10" target-lexicon = "0.10"
winit = "0.22" winit = "0.22"
wgpu = "0.6" wgpu = "0.6"