Centralize S2E opcodes register usage definition

Make more esplicit the register usage of custom S2E opcodes.
This helps documenting the ASM interface and at the same time
removes a lot of target-specific code in favor of compile-time
constants.

Signed-off-by: Luca Bruno <lucab@debian.org>
BaseInstructions: move debug to proper stream

Signed-off-by: Luca Bruno <lucab@debian.org>
BaseInstructions: enable sleep opcode for ARM

Signed-off-by: Luca Bruno <lucab@debian.org>
EdgeKiller: enable plugin for ARM

Signed-off-by: Luca Bruno <lucab@debian.org>
CacheSim: enable plugin for ARM

Signed-off-by: Luca Bruno <lucab@debian.org>
qemu-arm: bugfix: env is RO when the tlb is filled

An update of env will cause klee to throw an error:
"""
KLEE: ERROR: memory error: object read only
KLEE: NOTE: now ignoring this error at this location
"""

To trigger the error the following test case can be used:

	/* assuming D is not in the TLB */
	#define D (*((unsigned int *)0x85000000))

	static void my_test(void)
	{
	    char b;
	    s2e_make_symbolic(&b, 1, "my_buf");

	    if (b == 'A') {
	        D = 0;
	        s2e_kill_state(0, "A");
	    } else {
	        s2e_kill_state(0, "not A");
	    }
	}

The fix is just an old hack that has been introduced in the commit:
394a0e3b999c9c4d76691ff81163731d908cdebb

Signed-off-by: Lucian Cojocar <cojocar@gmail.com>
s2e-arm: bugfix: pass message pointer in r0 for s2earm calls

The pointer to the message for the s2e_{message,warning} calls was not
set in the 'r0' register.

Signed-off-by: Lucian Cojocar <cojocar@gmail.com>
Emit instr_translate_start also in full ARM mode

Signed-off-by: Luca BRUNO <lucab@debian.org>
Implemented execution state getFlags() function for ARM

Signed-off-by: Jonas Zaddach <zaddach@eurecom.fr>
Uniform opcodes handling across architectures

Signed-off-by: Luca Bruno <lucab@debian.org>
RawMonitor: port plugin to ARM

Make RawMonitor plugin no more x86-dependent, port to ARM and enable it
on all architectures.

Signed-off-by: Luca Bruno <lucab@debian.org>
ModuleExecutionDetector: port plugin to ARM

Signed-off-by: Luca Bruno <lucab@debian.org>
Add more helpers for banked register

Add getters and setters for banked spsr and lr registers.

Signed-off-by: Luca Bruno <lucab@debian.org>
Add missing include

Signed-off-by: Luca BRUNO <lucab@debian.org>
Move S2E ARM tests in a separate repository

Signed-off-by: Luca Bruno <lucab@debian.org>
Make guest tools more arch independent

Signed-off-by: Luca Bruno <lucab@debian.org>
Annotation: enable plugin on ARM

Signed-off-by: Luca Bruno <lucab@debian.org>
Minor and cosmetic fixes

Signed-off-by: Luca Bruno <lucab@debian.org>
ConfigFile: fix reading and writing PC

Signed-off-by: Luca Bruno <lucab@debian.org>
CodeSelector: enable plugin on ARM

Signed-off-by: Luca BRUNO <lucab@debian.org>