Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
brainfucker
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Taddeüs Kroes
brainfucker
Commits
c86205d1
Commit
c86205d1
authored
Jan 10, 2015
by
Taddeüs Kroes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Small tweaks and cleanup
parent
81955ca5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
12 deletions
+10
-12
bf.ml
bf.ml
+1
-2
compare.sh
compare.sh
+9
-10
No files found.
bf.ml
View file @
c86205d1
...
...
@@ -183,8 +183,7 @@ let compile_c memsize program =
"#include <stdio.h>
\n
"
^
"#include <stdlib.h>
\n
"
^
"void _start() {
\n
"
^
" unsigned char mem["
^
string_of_int
memsize
^
"] = {};
\n
"
^
" unsigned char *p = mem;
\n
"
^
" unsigned char mem["
^
string_of_int
memsize
^
"] = {}, *p = mem;
\n
"
^
indent
(
compile_commands
""
program
)
^
" exit(0);
\n
"
^
"}
\n
"
...
...
compare.sh
View file @
c86205d1
...
...
@@ -10,19 +10,18 @@ fi
mytime
()
{
(
`
which
time
`
-f
%e
$1
>
/dev/null
)
2>&1
}
set
-e
echo
-n
"compiling opt..."
make
-s
$basename
-opt
echo
done
compile
()
{
echo
-n
"compiling
$1
... "
t
=
`
mytime
"make -s
$basename
-
$1
"
`
echo
"took
$t
seconds"
}
echo
-n
"compiling c..."
make
-s
$basename
-c
echo
done
set
-e
echo
-n
"compiling nayuki..."
make
-s
$basename
-nayuki
echo
done
compile opt
compile c
compile nayuki
echo
"opt:
`
mytime ./
$basename
-opt
`
"
echo
"c:
`
mytime ./
$basename
-c
`
"
...
...
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