PROLEAD
A Probing-Based Leakage Detection Tool for Hardware and Software
Loading...
Searching...
No Matches
arm_functions.h
Go to the documentation of this file.
1#pragma once
2
5
6#include <tuple>
7
9{
10 // armv6m
11 std::tuple<bool, u32, u8> shift_c(u32 value, ShiftType type, u8 amount, u8 carry_in);
12 std::tuple<bool, u32> shift(u32 value, ShiftType type, u8 amount, u8 carry_in);
13
14 std::tuple<bool, u32, u8> LSL_C(u32 x, u32 shift);
15 std::tuple<bool, u32> LSL(u32 x, u32 shift);
16
17 std::tuple<bool, u32, u8> LSR_C(u32 x, u32 shift);
18 std::tuple<bool, u32> LSR(u32 x, u32 shift);
19
20 std::tuple<bool, u32, u8> ASR_C(u32 x, u32 shift);
21 std::tuple<bool, u32> ASR(u32 x, u32 shift);
22
23 std::tuple<bool, u32, u8> ROR_C(u32 x, u32 shift);
24 std::tuple<bool, u32> ROR(u32 x, u32 shift);
25
26 std::tuple<bool, u32, u8> RRX_C(u32 x, u8 carry_in);
27 std::tuple<bool, u32> RRX(u32 x, u8 carry_in);
28
29 std::tuple<u32, u8, u8> add_with_carry(u32 x, u32 y, u8 carry_in);
30
31 u32 align(u32 address, u32 alignment);
32
33 std::tuple<ShiftType, u32> decode_imm_shift(u8 type, u32 imm5);
35
36 u32 sign_extend(u32 value, u32 num_bits);
39
40 // armv7m
41 //std::tuple<u32, bool> signed_sat_Q(i32 i, u32 n);
42 std::tuple<u32, bool> signed_sat_Q(i64 i, u32 n);
43
44 std::tuple<u32, bool> unsigned_sat_Q(i32 i, u32 n);
45
47
49
50 std::tuple<u32, bool> sat_Q(i32 i, u32 n, bool unsigned_sat);
51
52 u32 sat(i32 i, u32 n, bool unsigned_sat);
53
54 std::tuple<bool, u32, u8> thumb_expand_imm_C(u32 imm, u8 carry_in);
55 std::tuple<bool, u32> thumb_expand_imm(u32 imm);
56}
std::tuple< bool, u32 > thumb_expand_imm(u32 imm)
std::tuple< ShiftType, u32 > decode_imm_shift(u8 type, u32 imm5)
std::tuple< bool, u32, u8 > ROR_C(u32 x, u32 shift)
std::tuple< u32, bool > unsigned_sat_Q(i32 i, u32 n)
u32 sat(i32 i, u32 n, bool unsigned_sat)
u32 bit_count(u32 value)
std::tuple< bool, u32, u8 > thumb_expand_imm_C(u32 imm, u8 carry_in)
ShiftType decode_reg_shift(u8 type)
std::tuple< bool, u32, u8 > shift_c(u32 value, ShiftType type, u8 amount, u8 carry_in)
u32 lowest_set_bit(u32 value)
std::tuple< bool, u32, u8 > LSL_C(u32 x, u32 shift)
u32 align(u32 address, u32 alignment)
std::tuple< bool, u32, u8 > LSR_C(u32 x, u32 shift)
std::tuple< u32, bool > sat_Q(i32 i, u32 n, bool unsigned_sat)
std::tuple< bool, u32 > shift(u32 value, ShiftType type, u8 amount, u8 carry_in)
std::tuple< u32, u8, u8 > add_with_carry(u32 x, u32 y, u8 carry_in)
std::tuple< u32, bool > signed_sat_Q(i64 i, u32 n)
std::tuple< bool, u32, u8 > RRX_C(u32 x, u8 carry_in)
u32 unsigned_sat(i32 i, u32 n)
u32 sign_extend(u32 value, u32 num_bits)
std::tuple< bool, u32, u8 > ASR_C(u32 x, u32 shift)
u32 signed_sat(i32 i, u32 n)
uint32_t u32
Definition: types.h:12
int32_t i32
Definition: types.h:17
uint8_t u8
Definition: types.h:10
int64_t i64
Definition: types.h:18