Török Edvin
52d0d8bc7e
More fixes for global vars in the interpreter.
2010-03-22 11:18:28 +02:00
Török Edvin
09667cdd3b
Print size and location of JITed code.
2010-03-22 11:18:28 +02:00
Török Edvin
6ad39a4099
zlib/buffer apis.
2010-03-22 11:18:28 +02:00
Török Edvin
75e18b29c2
minimalistic zlib api.
2010-03-22 11:18:28 +02:00
Török Edvin
b56bea54d3
New API for buffer fill.
2010-03-22 11:18:28 +02:00
Török Edvin
aa745db74d
Add clamscan commandline to load bytecode in debug mode.
2010-03-12 13:13:08 +02:00
Török Edvin
f60c59a471
bb #1800 .
2010-03-10 11:44:55 +02:00
Török Edvin
04d11afedb
Update to new LLVM API.
...
ModuleProvider is gone!
2010-02-15 18:48:35 +02:00
Török Edvin
6eeadbfeda
dconf for bytecode.
2010-02-15 17:32:41 +02:00
Török Edvin
1e30496d2a
runtime checks verifier.
2010-02-15 17:32:41 +02:00
Török Edvin
236fb13647
New pointer handling rules.
2010-02-15 17:32:40 +02:00
Török Edvin
847d7fc1b8
2009->2010
2010-02-02 14:03:32 +02:00
Török Edvin
57bbb2eb14
Fix loading of multiple .cbc files.
...
Common function prototypes must be added only once per Module, otherwise LLVM autorenames
them, and we get llvm.bswap.i326 instead of llvm.bswap.i32, which is of course
not valid and the verifier rejects.
2010-02-02 14:01:38 +02:00
Török Edvin
bcb354a654
_GLIBCXX_PARALLEL is not supported: it creates threads before we fork() causing
...
deadlock.
2010-01-27 14:42:40 +02:00
Török Edvin
a7b7a64833
fix compiler warning.
2010-01-26 14:25:54 +02:00
Török Edvin
ee6ab4f8d3
Support building w/o atomic builtins for i386 (bb #1781 ).
...
Wrap all LLVM API calls with a single mutex when LLVM doesn't have multithreaded
mode.
Also fallback to interpreter mode on i386 and i486.
2010-01-26 12:44:49 +02:00
Török Edvin
be43f951c6
BytecodeSecurity setting.
2010-01-22 16:50:35 +02:00
Török Edvin
4395bb9acf
bytecode ptrdiff32 opcode.
2010-01-21 16:49:22 +02:00
Török Edvin
2d45ef0616
Support for malloc in bytecode. Fix crash with mismatched api/flevel versions.
2010-01-20 20:04:01 +02:00
Török Edvin
8997b14725
bswap.
2009-12-30 15:08:35 +02:00
Török Edvin
b3571ea9ae
Fix __*di3 libcalls on x86-32.
...
On 32-bit targets LLVM emits libcalls for 64-bit operations.
Make sure these libcalls actually map to our own functions, and not to 0.
Also reject any other libcall we don't know about instead of mapping to 0 and crashing.
2009-12-30 12:15:26 +02:00
Török Edvin
c52e92748e
Fix some warnings from clang++ bytecode2llvm.cpp.
2009-12-28 20:18:59 +02:00
Török Edvin
8d18898743
add regalloc local for debug purposes.
2009-12-18 15:04:23 +02:00
Török Edvin
9463f9fd90
Stack protector support.
2009-12-18 14:17:50 +02:00
Török Edvin
688799d126
yc_bytecode is able to unpack a file now!
2009-12-17 17:40:35 +02:00
Török Edvin
3cd48316a3
Fix some compiler warnings.
2009-12-17 10:59:26 +02:00
Török Edvin
5b91dc3455
new deplibs.
2009-12-15 18:15:28 +02:00
Török Edvin
303c6ea016
Minimum required version for multithreaded LLVM is gcc 4.1.3.
...
gcc 3.4.6 doesn't support atomic builtins required by LLVM for multithreaded
mode.
So make the minimum version 4.1.3, since: 4.0 is buggy for ClamAV itself, and
4.1.1, 4.1.2 are buggy when compiling LLVM.
On gcc 3.4.6 clamav will use the interpreter now.
2009-12-14 16:23:22 +02:00
Török Edvin
853b6e5da1
Add LLVM win32 proj files generated by cmake.
...
Fix win32 build issues.
Enable CPU detection on win32 too.
Enable LLVM JIT on win32 too.
Define NDEBUG for libclamavc++ for release win32 builds.
2009-12-12 15:14:39 +02:00
Török Edvin
d0934caf99
Distcheck fixes.
2009-12-11 21:02:19 +02:00
Török Edvin
482e97dbb2
Support for bytecode lines >8k.
...
Size is specified on first line (which must be <8k).
2009-12-11 16:05:38 +02:00
Török Edvin
7945ff1e97
Fix global initializer bitcasts.
2009-12-11 12:08:32 +02:00
Török Edvin
0a11015bf5
Refactor trace API, so that trace printing happens in clambc.
...
This will allow clambc to implement breakpoints, and watchpoints.
2009-12-09 17:05:05 +02:00
Török Edvin
284ffd21f2
Add support for null constant.
2009-12-09 15:15:35 +02:00
Török Edvin
124af5e8a5
Trace formatting fixes.
2009-12-09 11:43:17 +02:00
Török Edvin
65c740d7d8
Add support for tracing (if bytecode compiled with support).
...
TODO: global id 0 is now a null pointer, need to adjust rest of conversion code
accordingly.
2009-12-08 23:02:49 +02:00
Török Edvin
53bd5bb14d
read optional debug metadata.
2009-11-30 15:22:20 +02:00
Török Edvin
d2171abf39
Print better error message when wrong function is called.
2009-11-27 15:57:13 +02:00
Török Edvin
6bd858662e
Update to new LLVM API.
2009-11-27 13:36:43 +02:00
Török Edvin
1f1a249720
Disable oprofile support for now.
2009-11-27 12:25:46 +02:00
Török Edvin
322a0ea653
Fix bytecode load bugs. Make loading more robust: print error message instead of
...
crashing.
Able to load and dry-run yc_bytecode.o1.cbc now.
2009-11-26 17:29:59 +02:00
Török Edvin
a45e257772
Fix bugs when loading bytecode.
2009-11-26 17:29:45 +02:00
Török Edvin
646395bb44
Fix distcheck.
2009-10-02 12:52:35 +03:00
Török Edvin
9fac78c72e
Update to latest bytecode format.
2009-10-02 10:26:47 +03:00
Török Edvin
80b4b3fb0f
Generalize special global handling (__match_counts etc.).
2009-09-30 14:06:10 +03:00
Török Edvin
88815fd801
Sync with compiler.
2009-09-30 13:41:02 +03:00
Török Edvin
d38d6dadef
Logical signature hook for bytecode.
2009-09-22 11:04:33 +03:00
Török Edvin
459b13ed89
Initial support for __match_count.
2009-09-21 23:44:32 +03:00
Török Edvin
52dd3a6bda
Initial support for loading .cbc files from DB.
2009-09-21 20:10:33 +03:00
Török Edvin
1d1dd80f32
Fix global variable names.
2009-09-11 15:17:48 +03:00