Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mu-impl-fast
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
40
Issues
40
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
mu
mu-impl-fast
Commits
beeb1630
Commit
beeb1630
authored
Sep 11, 2017
by
qinsoon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use main_test.c for tests
parent
fad24db1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
5 deletions
+13
-5
aot.rs
src/linkutils/aot.rs
+1
-1
main_test.c
src/runtime/main_test.c
+12
-4
No files found.
src/linkutils/aot.rs
View file @
beeb1630
...
...
@@ -103,7 +103,7 @@ pub fn link_test_primordial(funcs: Vec<MuName>, out: &str, vm: &VM) -> PathBuf {
ret
.push
(
get_path_for_mu_context
(
vm
));
// copy primoridal entry
let
source
=
get_path_under_zebu
(
runtime
::
PRIMORDIAL_ENTRY
);
let
source
=
get_path_under_zebu
(
runtime
::
TEST_
PRIMORDIAL_ENTRY
);
let
dest
=
{
let
mut
ret
=
PathBuf
::
from
(
&
vm
.vm_options.flag_aot_emit_dir
);
ret
.push
(
"main_test.c"
);
...
...
src/runtime/main_test.c
View file @
beeb1630
// Copyright 2017 The Australian National University
//
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//
// http://www.apache.org/licenses/LICENSE-2.0
//
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
...
...
@@ -27,7 +27,15 @@ extern void* rodal_realloc(void*, size_t);
extern
uint32_t
mu_retval
;
extern
void
*
STRUCT_TAG_MAP
;
extern
void
*
HYBRID_TAG_MAP
;
extern
void
*
STRUCT_TAG_MAP_LOC
;
extern
void
*
HYBRID_TAG_MAP_LOC
;
int
main
(
int
argc
,
char
**
argv
)
{
STRUCT_TAG_MAP_LOC
=
&
STRUCT_TAG_MAP
;
HYBRID_TAG_MAP_LOC
=
&
HYBRID_TAG_MAP
;
rodal_init_deallocate
();
mu_main
(
&
RODAL_END
,
&
vm
,
argc
,
argv
);
assert
(
mu_retval
==
0
);
...
...
@@ -35,4 +43,4 @@ int main(int argc, char** argv) {
}
void
free
(
void
*
ptr
)
{
return
rodal_free
(
ptr
);
};
void
*
realloc
(
void
*
ptr
,
size_t
s
)
{
return
rodal_realloc
(
ptr
,
s
);
};
void
*
realloc
(
void
*
ptr
,
size_t
s
)
{
return
rodal_realloc
(
ptr
,
s
);
};
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment