diff options
| author | Richard M. Stallman | 1995-02-16 06:36:19 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-02-16 06:36:19 +0000 |
| commit | 6d16dd06fb4ef6b7056d5f75ab10ac0852b7c047 (patch) | |
| tree | 167778f1861233f03d5709d45afdf66422e4c481 /src | |
| parent | 8cd1ad32be3e471ba6b27166333b4a51aee1b649 (diff) | |
| download | emacs-6d16dd06fb4ef6b7056d5f75ab10ac0852b7c047.tar.gz emacs-6d16dd06fb4ef6b7056d5f75ab10ac0852b7c047.zip | |
Whitespace fixes.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ralloc.c | 158 |
1 files changed, 79 insertions, 79 deletions
diff --git a/src/ralloc.c b/src/ralloc.c index a0731eee6fc..42c5eec4fc7 100644 --- a/src/ralloc.c +++ b/src/ralloc.c | |||
| @@ -1014,84 +1014,84 @@ r_alloc_init () | |||
| 1014 | int | 1014 | int |
| 1015 | r_alloc_check () | 1015 | r_alloc_check () |
| 1016 | { | 1016 | { |
| 1017 | int found = 0; | 1017 | int found = 0; |
| 1018 | heap_ptr h, ph = 0; | 1018 | heap_ptr h, ph = 0; |
| 1019 | bloc_ptr b, pb = 0; | 1019 | bloc_ptr b, pb = 0; |
| 1020 | 1020 | ||
| 1021 | if (!r_alloc_initialized) | 1021 | if (!r_alloc_initialized) |
| 1022 | return; | 1022 | return; |
| 1023 | 1023 | ||
| 1024 | assert (first_heap); | 1024 | assert (first_heap); |
| 1025 | assert (last_heap->end <= (POINTER) sbrk (0)); | 1025 | assert (last_heap->end <= (POINTER) sbrk (0)); |
| 1026 | assert ((POINTER) first_heap < first_heap->start); | 1026 | assert ((POINTER) first_heap < first_heap->start); |
| 1027 | assert (first_heap->start <= virtual_break_value); | 1027 | assert (first_heap->start <= virtual_break_value); |
| 1028 | assert (virtual_break_value <= first_heap->end); | 1028 | assert (virtual_break_value <= first_heap->end); |
| 1029 | 1029 | ||
| 1030 | for (h = first_heap; h; h = h->next) | 1030 | for (h = first_heap; h; h = h->next) |
| 1031 | { | 1031 | { |
| 1032 | assert (h->prev == ph); | 1032 | assert (h->prev == ph); |
| 1033 | assert ((POINTER) ROUNDUP (h->end) == h->end); | 1033 | assert ((POINTER) ROUNDUP (h->end) == h->end); |
| 1034 | assert ((POINTER) MEM_ROUNDUP (h->start) == h->start); | 1034 | assert ((POINTER) MEM_ROUNDUP (h->start) == h->start); |
| 1035 | assert ((POINTER) MEM_ROUNDUP (h->bloc_start) == h->bloc_start); | 1035 | assert ((POINTER) MEM_ROUNDUP (h->bloc_start) == h->bloc_start); |
| 1036 | assert (h->start <= h->bloc_start && h->bloc_start <= h->end); | 1036 | assert (h->start <= h->bloc_start && h->bloc_start <= h->end); |
| 1037 | 1037 | ||
| 1038 | if (ph) | 1038 | if (ph) |
| 1039 | { | 1039 | { |
| 1040 | assert (ph->end < h->start); | 1040 | assert (ph->end < h->start); |
| 1041 | assert (h->start <= (POINTER)h && (POINTER)(h+1) <= h->bloc_start); | 1041 | assert (h->start <= (POINTER)h && (POINTER)(h+1) <= h->bloc_start); |
| 1042 | } | 1042 | } |
| 1043 | 1043 | ||
| 1044 | if (h->bloc_start <= break_value && break_value <= h->end) | 1044 | if (h->bloc_start <= break_value && break_value <= h->end) |
| 1045 | found = 1; | 1045 | found = 1; |
| 1046 | 1046 | ||
| 1047 | ph = h; | 1047 | ph = h; |
| 1048 | } | 1048 | } |
| 1049 | 1049 | ||
| 1050 | assert (found); | 1050 | assert (found); |
| 1051 | assert (last_heap == ph); | 1051 | assert (last_heap == ph); |
| 1052 | 1052 | ||
| 1053 | for (b = first_bloc; b; b = b->next) | 1053 | for (b = first_bloc; b; b = b->next) |
| 1054 | { | 1054 | { |
| 1055 | assert (b->prev == pb); | 1055 | assert (b->prev == pb); |
| 1056 | assert ((POINTER) MEM_ROUNDUP (b->data) == b->data); | 1056 | assert ((POINTER) MEM_ROUNDUP (b->data) == b->data); |
| 1057 | assert ((SIZE) MEM_ROUNDUP (b->size) == b->size); | 1057 | assert ((SIZE) MEM_ROUNDUP (b->size) == b->size); |
| 1058 | 1058 | ||
| 1059 | ph = 0; | 1059 | ph = 0; |
| 1060 | for (h = first_heap; h; h = h->next) | 1060 | for (h = first_heap; h; h = h->next) |
| 1061 | { | 1061 | { |
| 1062 | if (h->bloc_start <= b->data && b->data + b->size <= h->end) | 1062 | if (h->bloc_start <= b->data && b->data + b->size <= h->end) |
| 1063 | break; | 1063 | break; |
| 1064 | ph = h; | 1064 | ph = h; |
| 1065 | } | 1065 | } |
| 1066 | 1066 | ||
| 1067 | assert (h); | 1067 | assert (h); |
| 1068 | 1068 | ||
| 1069 | if (pb && pb->data + pb->size != b->data) | 1069 | if (pb && pb->data + pb->size != b->data) |
| 1070 | { | 1070 | { |
| 1071 | assert (ph && b->data == h->bloc_start); | 1071 | assert (ph && b->data == h->bloc_start); |
| 1072 | while (ph) | 1072 | while (ph) |
| 1073 | { | 1073 | { |
| 1074 | if (ph->bloc_start <= pb->data | 1074 | if (ph->bloc_start <= pb->data |
| 1075 | && pb->data + pb->size <= ph->end) | 1075 | && pb->data + pb->size <= ph->end) |
| 1076 | { | 1076 | { |
| 1077 | assert (pb->data + pb->size + b->size > ph->end); | 1077 | assert (pb->data + pb->size + b->size > ph->end); |
| 1078 | break; | 1078 | break; |
| 1079 | } | 1079 | } |
| 1080 | else | 1080 | else |
| 1081 | { | 1081 | { |
| 1082 | assert (ph->bloc_start + b->size > ph->end); | 1082 | assert (ph->bloc_start + b->size > ph->end); |
| 1083 | } | 1083 | } |
| 1084 | ph = ph->prev; | 1084 | ph = ph->prev; |
| 1085 | } | 1085 | } |
| 1086 | } | 1086 | } |
| 1087 | pb = b; | 1087 | pb = b; |
| 1088 | } | 1088 | } |
| 1089 | 1089 | ||
| 1090 | assert (last_bloc == pb); | 1090 | assert (last_bloc == pb); |
| 1091 | 1091 | ||
| 1092 | if (last_bloc) | 1092 | if (last_bloc) |
| 1093 | assert (last_bloc->data + last_bloc->size == break_value); | 1093 | assert (last_bloc->data + last_bloc->size == break_value); |
| 1094 | else | 1094 | else |
| 1095 | assert (first_heap->bloc_start == break_value); | 1095 | assert (first_heap->bloc_start == break_value); |
| 1096 | } | 1096 | } |
| 1097 | #endif /* DEBUG */ | 1097 | #endif /* DEBUG */ |