don't link mmap region into .text but aot array itself
This commit is contained in:
10
flake.nix
10
flake.nix
@ -322,14 +322,8 @@ rec {
|
||||
domain = "gitea.local.chriphost.de";
|
||||
owner = "christoph";
|
||||
repo = "wamr";
|
||||
|
||||
# After placing mmap region in .text segment:
|
||||
rev = "1521011029b0531c02eb0142c239b7f85a3165b5";
|
||||
hash = "sha256-/uLSank+Aacfj+SBliYTaD320cCA1lBRtSRALXErJGE=";
|
||||
|
||||
# Before placing mmap region in .text segment:
|
||||
# rev = "fd69a4e76ec0d384bd79f514772b7dfa240fc0d7";
|
||||
# hash = "sha256-rlCx4isI0k6rC9E0hWIA9LeinqiACug7zxj9z/e4SBQ=";
|
||||
rev = "4e7aed33fe53bf3ee4a3f2fe582c74816f850759";
|
||||
hash = "sha256-/4BKwoFDRfkA+DmbWagxdtkCDAED5rxbz5e4xvjvVWU=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = with pkgs; [cmake];
|
||||
|
||||
@ -32,6 +32,9 @@ my $cui = TUI::init_cui();
|
||||
|
||||
# TODO: Add a TextEditor panel below the markers for notes.
|
||||
# Store notes in ./notes/benchmark-type-address.txt
|
||||
# TODO: Add a more exhaustive faults query that also retrieves
|
||||
# what fault has been injected. Then add an info popup or
|
||||
# display it in the markers panel
|
||||
|
||||
# =============================================================================
|
||||
# Data handling
|
||||
|
||||
@ -139,7 +139,13 @@ my %handlers = (
|
||||
"$local_archive_dir/$selected_experiment/system.elf" );
|
||||
},
|
||||
|
||||
'13. Run Build in GDB' => sub {
|
||||
'13. Open Experiment in ResultBrowser' => sub {
|
||||
|
||||
# TODO: Select from existing DBs, rewrite db.conf,
|
||||
# launch resultbrowser + firefox
|
||||
},
|
||||
|
||||
'14. Run Build in GDB' => sub {
|
||||
my @builds = grep { /linux/ } Util::find_subdirs($local_builds_dir);
|
||||
my @selected_builds =
|
||||
TUI::select_from_list( "Select Build to Run", 0, @builds );
|
||||
|
||||
@ -206,8 +206,7 @@ sub inject {
|
||||
"-Wf,--state-dir=$remote_builds_dir/$experiment/state",
|
||||
"-Wf,--trap",
|
||||
"-Wf,--catch-outerspace",
|
||||
|
||||
# "-Wf,--catch-write-textsegment",
|
||||
"-Wf,--catch-write-textsegment",
|
||||
"-Wf,--timeout=500000",
|
||||
"-Wf,--ok-marker=fail_marker_positive",
|
||||
"-Wf,--fail-marker=fail_marker_negative",
|
||||
|
||||
@ -97,6 +97,9 @@ build-wasm-aot module target="fail":
|
||||
build-wasm-aot-array module:
|
||||
{{ XXD }} -i {{ BUILD_DIR }}-{{ module }}/wasm_module.aot > {{ BUILD_DIR }}-{{ module }}/wasm_aot_array.c
|
||||
|
||||
# Add __attribute__((section...)) to this array, so it is located into the .text.wamr_aot segment...
|
||||
sed -i '1s/^/__attribute__((section(".text.wamr_aot"), aligned(4096)))\n/' {{ BUILD_DIR }}-{{ module }}/wasm_aot_array.c
|
||||
|
||||
[doc("WASM -> C-Array: Dump a WASM module to a binary array")]
|
||||
[group("1: build module")]
|
||||
build-wasm-interp-array module:
|
||||
|
||||
@ -51,8 +51,8 @@ SECTIONS {
|
||||
|
||||
/* Data and Stacks */
|
||||
/* NOTE: When including the WAMR mmap region inside .text, it has to be large */
|
||||
/* . = 0x200000; */
|
||||
. = ALIGN(4096);
|
||||
. = 0x200000;
|
||||
/* . = ALIGN(4096); */
|
||||
.data : {
|
||||
KEEP (*(".startup_stack"))
|
||||
KEEP (*(".kernel_stack"))
|
||||
|
||||
Reference in New Issue
Block a user