Commit 099669a
committed
Verify memory usage: Re-use t1/w1 buffer
This commit is the first of a series of commits reducing the stack usage of
verification.
It is hoisted out from #751
This commit places the t1 and w1 buffers into a union saving K KiB of memory.
Operations using it are slightly reordered such that their lifetime does not
overlap.
As CBMC struggles with unions (issue 8813), we use the same workaround
present in signing: Use a struct by default, and a union when
MLD_CONFIG_REDUCE_RAM is set.
Signed-off-by: Matthias J. Kannwischer <matthias@kannwischer.eu>1 parent 052ee8d commit 099669a
2 files changed
Lines changed: 24 additions & 15 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
839 | 839 | | |
840 | 840 | | |
841 | 841 | | |
842 | | - | |
| 842 | + | |
843 | 843 | | |
844 | 844 | | |
845 | | - | |
| 845 | + | |
846 | 846 | | |
847 | 847 | | |
848 | | - | |
| 848 | + | |
849 | 849 | | |
850 | 850 | | |
851 | 851 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
965 | 965 | | |
966 | 966 | | |
967 | 967 | | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
| 971 | + | |
| 972 | + | |
| 973 | + | |
| 974 | + | |
| 975 | + | |
| 976 | + | |
| 977 | + | |
| 978 | + | |
| 979 | + | |
968 | 980 | | |
969 | 981 | | |
970 | 982 | | |
| |||
973 | 985 | | |
974 | 986 | | |
975 | 987 | | |
976 | | - | |
977 | | - | |
| 988 | + | |
978 | 989 | | |
979 | 990 | | |
980 | 991 | | |
981 | 992 | | |
982 | | - | |
983 | | - | |
| 993 | + | |
| 994 | + | |
984 | 995 | | |
985 | 996 | | |
986 | 997 | | |
987 | 998 | | |
| 999 | + | |
| 1000 | + | |
988 | 1001 | | |
989 | 1002 | | |
990 | 1003 | | |
| |||
1027 | 1040 | | |
1028 | 1041 | | |
1029 | 1042 | | |
1030 | | - | |
1031 | | - | |
1032 | | - | |
1033 | | - | |
1034 | | - | |
1035 | 1043 | | |
1036 | 1044 | | |
1037 | 1045 | | |
1038 | | - | |
1039 | 1046 | | |
1040 | 1047 | | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
1041 | 1051 | | |
1042 | 1052 | | |
1043 | 1053 | | |
| |||
1061 | 1071 | | |
1062 | 1072 | | |
1063 | 1073 | | |
1064 | | - | |
1065 | | - | |
| 1074 | + | |
1066 | 1075 | | |
1067 | 1076 | | |
1068 | 1077 | | |
| |||
0 commit comments