aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--AUTHORS3
-rw-r--r--emscripten-version.txt2
-rw-r--r--src/library.js10
-rw-r--r--src/library_fs.js14
-rw-r--r--src/relooper/Relooper.cpp114
-rw-r--r--src/relooper/Relooper.h14
-rw-r--r--src/settings.js2
-rw-r--r--tests/fuzz/19.c1408
-rw-r--r--tests/fuzz/19.c.txt1
-rw-r--r--tests/sdl_touch.c9
-rw-r--r--tests/test_core.py6
-rw-r--r--tools/eliminator/asm-eliminator-test-output.js52
-rw-r--r--tools/eliminator/asm-eliminator-test.js23
-rw-r--r--tools/js-optimizer.js17
14 files changed, 1584 insertions, 91 deletions
diff --git a/AUTHORS b/AUTHORS
index ad372e92..e0038c77 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -134,4 +134,7 @@ a license to everyone to use it as detailed in LICENSE.)
* Daniele Di Proietto <daniele.di.proietto@gmail.com>
* Dan Dascalescu <dNOSPAMdascalescu@gmail.com>
* Thomas Borsos <thomasborsos@gmail.com>
+* Ori Avtalion <ori@avtalion.name>
* Guillaume Blanc <guillaumeblanc.sc@gmail.com>
+
+
diff --git a/emscripten-version.txt b/emscripten-version.txt
index db39b14c..f488f67e 100644
--- a/emscripten-version.txt
+++ b/emscripten-version.txt
@@ -1,2 +1,2 @@
-1.15.1
+1.16.0
diff --git a/src/library.js b/src/library.js
index 1d5a9140..c2830397 100644
--- a/src/library.js
+++ b/src/library.js
@@ -3908,12 +3908,18 @@ LibraryManager.library = {
{{{ makeCopyValues('(ppdest+'+Runtime.QUANTUM_SIZE+')', '(ppsrc+'+Runtime.QUANTUM_SIZE+')', Runtime.QUANTUM_SIZE, 'null', null, 1) }}};
},
+ llvm_bswap_i16__asm: true,
+ llvm_bswap_i16__sig: 'ii',
llvm_bswap_i16: function(x) {
- return ((x&0xff)<<8) | ((x>>8)&0xff);
+ x = x|0;
+ return (((x&0xff)<<8) | ((x>>8)&0xff))|0;
},
+ llvm_bswap_i32__asm: true,
+ llvm_bswap_i32__sig: 'ii',
llvm_bswap_i32: function(x) {
- return ((x&0xff)<<24) | (((x>>8)&0xff)<<16) | (((x>>16)&0xff)<<8) | (x>>>24);
+ x = x|0;
+ return (((x&0xff)<<24) | (((x>>8)&0xff)<<16) | (((x>>16)&0xff)<<8) | (x>>>24))|0;
},
llvm_bswap_i64__deps: ['llvm_bswap_i32'],
diff --git a/src/library_fs.js b/src/library_fs.js
index 3d0036ee..d53210f9 100644
--- a/src/library_fs.js
+++ b/src/library_fs.js
@@ -394,16 +394,12 @@ mergeInto(LibraryManager.library, {
}
});
}
- if (stream.__proto__) {
- // reuse the object
- stream.__proto__ = FS.FSStream.prototype;
- } else {
- var newStream = new FS.FSStream();
- for (var p in stream) {
- newStream[p] = stream[p];
- }
- stream = newStream;
+ // clone it, so we can return an instance of FSStream
+ var newStream = new FS.FSStream();
+ for (var p in stream) {
+ newStream[p] = stream[p];
}
+ stream = newStream;
var fd = FS.nextfd(fd_start, fd_end);
stream.fd = fd;
FS.streams[fd] = stream;
diff --git a/src/relooper/Relooper.cpp b/src/relooper/Relooper.cpp
index 780a6d59..ce9232d9 100644
--- a/src/relooper/Relooper.cpp
+++ b/src/relooper/Relooper.cpp
@@ -243,7 +243,7 @@ void Block::Render(bool InLoop) {
Details = ProcessedBranchesOut[DefaultTarget];
}
bool SetCurrLabel = (SetLabel && Target->IsCheckedMultipleEntry) || ForceSetLabel;
- bool HasFusedContent = Fused && contains(Fused->InnerMap, Target);
+ bool HasFusedContent = Fused && contains(Fused->InnerMap, Target->Id);
bool HasContent = SetCurrLabel || Details->Type != Branch::Direct || HasFusedContent || Details->Code;
if (iter != ProcessedBranchesOut.end()) {
// If there is nothing to show in this branch, omit the condition
@@ -286,7 +286,7 @@ void Block::Render(bool InLoop) {
if (!First) Indenter::Indent();
Details->Render(Target, SetCurrLabel);
if (HasFusedContent) {
- Fused->InnerMap.find(Target)->second->Render(InLoop);
+ Fused->InnerMap.find(Target->Id)->second->Render(InLoop);
} else if (Details->Type == Branch::Nested) {
// Nest the parent content here, and remove it from showing up afterwards as Next
assert(Parent->Next);
@@ -312,18 +312,28 @@ void Block::Render(bool InLoop) {
// MultipleShape
void MultipleShape::RenderLoopPrefix() {
- if (NeedLoop) {
- if (Labeled) {
- PrintIndented("L%d: do {\n", Id);
+ if (Breaks) {
+ if (UseSwitch) {
+ if (Labeled) {
+ PrintIndented("L%d: ", Id);
+ }
} else {
- PrintIndented("do {\n");
+ if (Labeled) {
+ if (UseSwitch) {
+ PrintIndented("L%d: ", Id);
+ } else {
+ PrintIndented("L%d: do {\n", Id);
+ }
+ } else {
+ PrintIndented("do {\n");
+ }
+ Indenter::Indent();
}
- Indenter::Indent();
}
}
void MultipleShape::RenderLoopPostfix() {
- if (NeedLoop) {
+ if (Breaks && !UseSwitch) {
Indenter::Unindent();
PrintIndented("} while(0);\n");
}
@@ -332,32 +342,41 @@ void MultipleShape::RenderLoopPostfix() {
void MultipleShape::Render(bool InLoop) {
RenderLoopPrefix();
- // We know that blocks with the same Id were split from the same source, so their contents are identical and they are logically the same, so re-merge them here
- typedef std::map<int, Shape*> IdShapeMap;
- IdShapeMap IdMap;
- for (BlockShapeMap::iterator iter = InnerMap.begin(); iter != InnerMap.end(); iter++) {
- int Id = iter->first->Id;
- IdShapeMap::iterator Test = IdMap.find(Id);
- if (Test != IdMap.end()) {
- assert(Shape::IsSimple(iter->second) && Shape::IsSimple(Test->second)); // we can only merge simple blocks, something horrible has gone wrong if we see anything else
- continue;
+ if (!UseSwitch) {
+ // emit an if-else chain
+ bool First = true;
+ for (IdShapeMap::iterator iter = InnerMap.begin(); iter != InnerMap.end(); iter++) {
+ if (AsmJS) {
+ PrintIndented("%sif ((label|0) == %d) {\n", First ? "" : "else ", iter->first);
+ } else {
+ PrintIndented("%sif (label == %d) {\n", First ? "" : "else ", iter->first);
+ }
+ First = false;
+ Indenter::Indent();
+ iter->second->Render(InLoop);
+ Indenter::Unindent();
+ PrintIndented("}\n");
}
- IdMap[iter->first->Id] = iter->second;
- }
-
- bool First = true;
- for (IdShapeMap::iterator iter = IdMap.begin(); iter != IdMap.end(); iter++) {
+ } else {
+ // emit a switch
if (AsmJS) {
- PrintIndented("%sif ((label|0) == %d) {\n", First ? "" : "else ", iter->first);
+ PrintIndented("switch (label|0) {\n");
} else {
- PrintIndented("%sif (label == %d) {\n", First ? "" : "else ", iter->first);
+ PrintIndented("switch (label) {\n");
}
- First = false;
Indenter::Indent();
- iter->second->Render(InLoop);
+ for (IdShapeMap::iterator iter = InnerMap.begin(); iter != InnerMap.end(); iter++) {
+ PrintIndented("case %d: {\n", iter->first);
+ Indenter::Indent();
+ iter->second->Render(InLoop);
+ PrintIndented("break;\n");
+ Indenter::Unindent();
+ PrintIndented("}\n");
+ }
Indenter::Unindent();
PrintIndented("}\n");
}
+
RenderLoopPostfix();
if (Next) Next->Render(InLoop);
}
@@ -547,7 +566,7 @@ void Relooper::Calculate(Block *Entry) {
PriorOut->Ancestor = Ancestor;
PriorOut->Type = Type;
if (MultipleShape *Multiple = Shape::IsMultiple(Ancestor)) {
- Multiple->NeedLoop++; // We are breaking out of this Multiple, so need a loop
+ Multiple->Breaks++; // We are breaking out of this Multiple, so need a loop
}
iter++; // carefully increment iter before erasing
Target->BranchesIn.erase(Prior);
@@ -853,7 +872,7 @@ void Relooper::Calculate(Block *Entry) {
iter = Next; // increment carefully because Solipsize can remove us
}
}
- Multiple->InnerMap[CurrEntry] = Process(CurrBlocks, CurrEntries, NULL);
+ Multiple->InnerMap[CurrEntry->Id] = Process(CurrBlocks, CurrEntries, NULL);
// If we are not fused, then our entries will actually be checked
if (!Fused) {
CurrEntry->IsCheckedMultipleEntry = true;
@@ -867,6 +886,11 @@ void Relooper::Calculate(Block *Entry) {
NextEntries.insert(Entry);
}
}
+ // The multiple has been created, we can decide how to implement it
+ if (Multiple->InnerMap.size() >= 10) {
+ Multiple->UseSwitch = true;
+ Multiple->Breaks++; // switch captures breaks
+ }
return Multiple;
}
@@ -1021,7 +1045,7 @@ void Relooper::Calculate(Block *Entry) {
PostOptimizer(Relooper *ParentInit) : Parent(ParentInit), Closure(NULL) {}
#define RECURSE_Multiple(shape, func) \
- for (BlockShapeMap::iterator iter = shape->InnerMap.begin(); iter != shape->InnerMap.end(); iter++) { \
+ for (IdShapeMap::iterator iter = shape->InnerMap.begin(); iter != shape->InnerMap.end(); iter++) { \
func(iter->second); \
}
#define RECURSE_Loop(shape, func) \
@@ -1042,7 +1066,7 @@ void Relooper::Calculate(Block *Entry) {
SHAPE_SWITCH(S, {
Out.insert(Simple->Inner);
}, {
- for (BlockShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
+ for (IdShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
FollowNaturalFlow(iter->second, Out);
}
FollowNaturalFlow(Multiple->Next, Out);
@@ -1061,7 +1085,7 @@ void Relooper::Calculate(Block *Entry) {
SHAPE_SWITCH(Root, {
}, {
- for (BlockShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
+ for (IdShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
FindNaturals(iter->second, Root->Natural);
}
}, {
@@ -1111,7 +1135,7 @@ void Relooper::Calculate(Block *Entry) {
if (Details->Type == Branch::Break) {
Details->Type = Branch::Direct;
if (MultipleShape *Multiple = Shape::IsMultiple(Details->Ancestor)) {
- Multiple->NeedLoop--;
+ Multiple->Breaks--;
}
} else {
assert(Details->Type == Branch::Direct);
@@ -1130,20 +1154,20 @@ void Relooper::Calculate(Block *Entry) {
if (Details->Type != Branch::Direct && contains(NaturalBlocks, Target)) { // note: cannot handle split blocks
Details->Type = Branch::Direct;
if (MultipleShape *Multiple = Shape::IsMultiple(Details->Ancestor)) {
- Multiple->NeedLoop--;
+ Multiple->Breaks--;
}
} else if (Details->Type == Branch::Break && LastLoop && LastLoop->Natural == Details->Ancestor->Natural) {
// it is important to simplify breaks, as simpler breaks enable other optimizations
Details->Labeled = false;
if (MultipleShape *Multiple = Shape::IsMultiple(Details->Ancestor)) {
- Multiple->NeedLoop--;
+ Multiple->Breaks--;
}
}
}
}
}, {
- for (BlockShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
- RemoveUnneededFlows(iter->second, Multiple->Next, Multiple->NeedLoop ? NULL : LastLoop);
+ for (IdShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
+ RemoveUnneededFlows(iter->second, Multiple->Next, Multiple->Breaks ? NULL : LastLoop);
}
Next = Multiple->Next;
}, {
@@ -1169,13 +1193,16 @@ void Relooper::Calculate(Block *Entry) {
SHAPE_SWITCH(Root, {
MultipleShape *Fused = Shape::IsMultiple(Root->Next);
// If we are fusing a Multiple with a loop into this Simple, then visit it now
- if (Fused && Fused->NeedLoop) {
+ if (Fused && Fused->Breaks) {
LoopStack.push(Fused);
}
if (Simple->Inner->BranchVar) {
LoopStack.push(NULL); // a switch means breaks are now useless, push a dummy
}
if (Fused) {
+ if (Fused->UseSwitch) {
+ LoopStack.push(NULL); // a switch means breaks are now useless, push a dummy
+ }
RECURSE_Multiple(Fused, FindLabeledLoops);
}
for (BlockBranchMap::iterator iter = Simple->Inner->ProcessedBranchesOut.begin(); iter != Simple->Inner->ProcessedBranchesOut.end(); iter++) {
@@ -1191,10 +1218,13 @@ void Relooper::Calculate(Block *Entry) {
}
}
}
+ if (Fused && Fused->UseSwitch) {
+ LoopStack.pop();
+ }
if (Simple->Inner->BranchVar) {
LoopStack.pop();
}
- if (Fused && Fused->NeedLoop) {
+ if (Fused && Fused->Breaks) {
LoopStack.pop();
}
if (Fused) {
@@ -1203,11 +1233,11 @@ void Relooper::Calculate(Block *Entry) {
Next = Root->Next;
}
}, {
- if (Multiple->NeedLoop) {
+ if (Multiple->Breaks) {
LoopStack.push(Multiple);
}
RECURSE(Multiple, FindLabeledLoops);
- if (Multiple->NeedLoop) {
+ if (Multiple->Breaks) {
LoopStack.pop();
}
Next = Root->Next;
@@ -1290,8 +1320,8 @@ void Debugging::Dump(Shape *S, const char *prefix) {
printf("<< Simple with block %d\n", Simple->Inner->Id);
}, {
printf("<< Multiple\n");
- for (BlockShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
- printf(" with entry %d\n", iter->first->Id);
+ for (IdShapeMap::iterator iter = Multiple->InnerMap.begin(); iter != Multiple->InnerMap.end(); iter++) {
+ printf(" with entry %d\n", iter->first);
}
}, {
printf("<< Loop\n");
diff --git a/src/relooper/Relooper.h b/src/relooper/Relooper.h
index 152bae0e..c86e63ac 100644
--- a/src/relooper/Relooper.h
+++ b/src/relooper/Relooper.h
@@ -132,8 +132,6 @@ struct SimpleShape : public Shape {
}
};
-typedef std::map<Block*, Shape*> BlockShapeMap;
-
// A shape that may be implemented with a labeled loop.
struct LabeledShape : public Shape {
bool Labeled; // If we have a loop, whether it needs to be labeled
@@ -141,12 +139,16 @@ struct LabeledShape : public Shape {
LabeledShape(ShapeType TypeInit) : Shape(TypeInit), Labeled(false) {}
};
+// Blocks with the same id were split and are identical, so we just care about ids in Multiple entries
+typedef std::map<int, Shape*> IdShapeMap;
+
struct MultipleShape : public LabeledShape {
- BlockShapeMap InnerMap; // entry block -> shape
- int NeedLoop; // If we have branches, we need a loop. This is a counter of loop requirements,
- // if we optimize it to 0, the loop is unneeded
+ IdShapeMap InnerMap; // entry block ID -> shape
+ int Breaks; // If we have branches on us, we need a loop (or a switch). This is a counter of requirements,
+ // if we optimize it to 0, the loop is unneeded
+ bool UseSwitch; // Whether to switch on label as opposed to an if-else chain
- MultipleShape() : LabeledShape(Multiple), NeedLoop(0) {}
+ MultipleShape() : LabeledShape(Multiple), Breaks(0), UseSwitch(false) {}
void RenderLoopPrefix();
void RenderLoopPostfix();
diff --git a/src/settings.js b/src/settings.js
index 8b046e95..bf16290b 100644
--- a/src/settings.js
+++ b/src/settings.js
@@ -39,7 +39,7 @@ var CHECK_SIGNS = 0; // Runtime errors for signing issues that need correcting.
var ASSERTIONS = 1; // Whether we should add runtime assertions, for example to
// check that each allocation to the stack does not
- // exceed it's size, whether all allocations (stack and static) are
+ // exceed its size, whether all allocations (stack and static) are
// of positive size, etc., whether we should throw if we encounter a bad __label__, i.e.,
// if code flow runs into a fault
// ASSERTIONS == 2 gives even more runtime checks
diff --git a/tests/fuzz/19.c b/tests/fuzz/19.c
new file mode 100644
index 00000000..d94318c5
--- /dev/null
+++ b/tests/fuzz/19.c
@@ -0,0 +1,1408 @@
+/*
+ * This is a RANDOMLY GENERATED PROGRAM.
+ *
+ * Generator: csmith 2.2.0
+ * Git version: bf42ffd
+ * Options: --no-volatiles --no-packed-struct --no-math64
+ * Seed: 2524651702
+ */
+
+#include "csmith.h"
+
+
+static long __undefined;
+
+/* --- Struct/Union Declarations --- */
+/* --- GLOBAL VARIABLES --- */
+static uint32_t g_2[5][1] = {{0xF1124F01L},{0x1F2C29A3L},{0xF1124F01L},{0x1F2C29A3L},{0xF1124F01L}};
+static int32_t g_3 = 0x3FA75C19L;
+static uint32_t g_14[6] = {0xD1A4E665L,0xD1A4E665L,0xD1A4E665L,0xD1A4E665L,0xD1A4E665L,0xD1A4E665L};
+static uint32_t g_15 = 18446744073709551615UL;
+static int32_t g_34 = 1L;
+static int8_t g_36 = 0x6DL;
+static uint8_t g_40[7] = {0xEAL,0xEAL,0xEAL,0xEAL,0xEAL,0xEAL,0xEAL};
+static uint8_t g_44 = 0UL;
+static uint8_t *g_43 = &g_44;
+static int32_t g_46 = 0x461302D9L;
+static int32_t g_51[2][8][3] = {{{0x0D357E8FL,0x604C38DBL,0x0D357E8FL},{0x0D357E8FL,0x349DDA4AL,0x1ADF561FL},{0x0D357E8FL,0x2D584125L,(-4L)},{0x0D357E8FL,0x604C38DBL,0x0D357E8FL},{0x0D357E8FL,0x349DDA4AL,0x1ADF561FL},{0x0D357E8FL,0x2D584125L,(-4L)},{0x0D357E8FL,0x604C38DBL,0x0D357E8FL},{0x0D357E8FL,0x349DDA4AL,0x1ADF561FL}},{{0x0D357E8FL,0x2D584125L,(-4L)},{0x0D357E8FL,0x1ADF561FL,(-10L)},{(-10L),0x0D357E8FL,0xCF8610F1L},{(-10L),(-4L),(-9L)},{(-10L),0x1ADF561FL,(-10L)},{(-10L),0x0D357E8FL,0xCF8610F1L},{(-10L),(-4L),(-9L)},{(-10L),0x1ADF561FL,(-10L)}}};
+static uint32_t g_52 = 0x171C63CCL;
+static uint32_t g_56 = 0xFBFBE831L;
+static uint32_t *g_55 = &g_56;
+static const int8_t * const g_132 = &g_36;
+static const int8_t * const *g_131 = &g_132;
+static int32_t g_140 = 0L;
+static int32_t *g_143 = &g_140;
+static uint8_t **g_175 = &g_43;
+static uint8_t **g_176 = &g_43;
+static uint8_t **g_177 = (void*)0;
+static int8_t *g_243[6][2][9] = {{{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36},{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36}},{{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36},{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36}},{{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36},{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36}},{{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36},{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36}},{{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36},{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36}},{{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36},{&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36,&g_36}}};
+static int8_t **g_242 = &g_243[5][1][5];
+static int8_t **g_245 = &g_243[5][1][5];
+static uint16_t g_251 = 0x6187L;
+static int8_t g_255 = 0xFEL;
+static int16_t g_290 = 0xF4DEL;
+static int16_t *g_289 = &g_290;
+static uint32_t g_294[5] = {0xFDB146E2L,0xFDB146E2L,0xFDB146E2L,0xFDB146E2L,0xFDB146E2L};
+static int32_t g_297[2] = {1L,1L};
+static int32_t *g_312[2][1][6] = {{{(void*)0,(void*)0,&g_51[0][3][1],(void*)0,(void*)0,&g_51[0][3][1]}},{{(void*)0,(void*)0,&g_51[0][3][1],(void*)0,(void*)0,&g_51[0][3][1]}}};
+static uint8_t g_320 = 0xD4L;
+static int16_t g_347 = 0x586CL;
+static int16_t g_419 = 0xDAAFL;
+static uint32_t g_477 = 0x661A1A9FL;
+static uint32_t g_705[6] = {1UL,1UL,1UL,1UL,1UL,1UL};
+static uint32_t ** const g_736 = &g_55;
+static uint32_t ** const *g_735 = &g_736;
+static uint8_t ****g_897 = (void*)0;
+static uint8_t ***g_905 = &g_175;
+static uint8_t ****g_904[3][6] = {{&g_905,&g_905,&g_905,&g_905,&g_905,&g_905},{&g_905,&g_905,&g_905,&g_905,&g_905,&g_905},{&g_905,&g_905,&g_905,&g_905,&g_905,&g_905}};
+static int32_t **g_961 = &g_312[1][0][4];
+static int32_t ***g_960 = &g_961;
+static uint16_t g_969 = 5UL;
+static int8_t ***g_1019[7][1][1] = {{{&g_242}},{{&g_242}},{{&g_242}},{{&g_242}},{{&g_242}},{{&g_242}},{{&g_242}}};
+static int8_t ****g_1018 = &g_1019[3][0][0];
+static int32_t g_1055 = (-8L);
+static uint32_t g_1099 = 0xAD3B6902L;
+static int32_t g_1132 = (-9L);
+static int16_t * const *g_1185 = &g_289;
+static int16_t * const * const *g_1184 = &g_1185;
+static int16_t g_1189 = 0L;
+static uint32_t **g_1238 = &g_55;
+static uint32_t ***g_1237[8][4][4] = {{{&g_1238,(void*)0,&g_1238,(void*)0},{&g_1238,(void*)0,&g_1238,&g_1238},{(void*)0,&g_1238,&g_1238,(void*)0},{(void*)0,&g_1238,(void*)0,&g_1238}},{{&g_1238,(void*)0,(void*)0,&g_1238},{&g_1238,&g_1238,&g_1238,(void*)0},{&g_1238,&g_1238,&g_1238,(void*)0},{&g_1238,(void*)0,&g_1238,&g_1238}},{{&g_1238,&g_1238,&g_1238,(void*)0},{&g_1238,&g_1238,&g_1238,&g_1238},{&g_1238,(void*)0,(void*)0,&g_1238},{(void*)0,&g_1238,(void*)0,(void*)0}},{{&g_1238,(void*)0,&g_1238,(void*)0},{&g_1238,&g_1238,(void*)0,(void*)0},{(void*)0,(void*)0,&g_1238,&g_1238},{&g_1238,&g_1238,&g_1238,&g_1238}},{{&g_1238,&g_1238,&g_1238,&g_1238},{&g_1238,&g_1238,&g_1238,&g_1238},{&g_1238,&g_1238,&g_1238,&g_1238},{&g_1238,(void*)0,(void*)0,(void*)0}},{{&g_1238,&g_1238,&g_1238,(void*)0},{&g_1238,(void*)0,&g_1238,(void*)0},{(void*)0,&g_1238,(void*)0,&g_1238},{&g_1238,(void*)0,(void*)0,&g_1238}},{{&g_1238,&g_1238,&g_1238,(void*)0},{&g_1238,&g_1238,&g_1238,&g_1238},{&g_1238,(void*)0,&g_1238,(void*)0},{&g_1238,&g_1238,&g_1238,(void*)0}},{{&g_1238,&g_1238,&g_1238,&g_1238},{(void*)0,(void*)0,&g_1238,&g_1238},{(void*)0,&g_1238,&g_1238,(void*)0},{&g_1238,&g_1238,&g_1238,&g_1238}}};
+static uint32_t ***g_1241 = (void*)0;
+static uint32_t g_1254[8][1][8] = {{{0x441F7909L,0x441F7909L,0UL,0x5B976413L,18446744073709551610UL,0UL,18446744073709551610UL,0x5B976413L}},{{0x0ECD52E7L,0x5B976413L,0x0ECD52E7L,0xD72EFABCL,0x5B976413L,0x6701CBD7L,0x6701CBD7L,0x5B976413L}},{{0x5B976413L,0x6701CBD7L,0x6701CBD7L,0x5B976413L,0xD72EFABCL,0x0ECD52E7L,0x5B976413L,0x0ECD52E7L}},{{0x5B976413L,18446744073709551610UL,0UL,18446744073709551610UL,0x5B976413L,0UL,0x441F7909L,0x441F7909L}},{{0x0ECD52E7L,18446744073709551610UL,0xD72EFABCL,0xD72EFABCL,18446744073709551610UL,0x0ECD52E7L,0x6701CBD7L,18446744073709551610UL}},{{0x441F7909L,0x6701CBD7L,0xD72EFABCL,0x441F7909L,0xD72EFABCL,0x6701CBD7L,0x441F7909L,0x0ECD52E7L}},{{18446744073709551610UL,0x5B976413L,0UL,0x441F7909L,0x441F7909L,0UL,0x5B976413L,18446744073709551610UL}},{{0x0ECD52E7L,0x441F7909L,0x6701CBD7L,0xD72EFABCL,0x441F7909L,0xD72EFABCL,0x6701CBD7L,0x441F7909L}}};
+static int16_t g_1285 = 0L;
+static uint8_t * const **g_1295 = (void*)0;
+static uint8_t g_1298 = 0xB8L;
+static int16_t g_1333 = 0x34D4L;
+static uint32_t g_1334 = 0x1191E655L;
+static int32_t g_1509 = 1L;
+static uint8_t ***g_1548 = &g_176;
+static uint8_t ***g_1549 = (void*)0;
+static uint8_t ***g_1550 = (void*)0;
+static uint8_t ***g_1551[3][5] = {{&g_176,&g_176,&g_176,&g_176,&g_176},{&g_176,&g_176,&g_176,&g_176,&g_176},{&g_176,&g_176,&g_176,&g_176,&g_176}};
+static uint8_t ***g_1552[10][9] = {{&g_175,&g_177,&g_175,(void*)0,&g_175,&g_175,(void*)0,&g_175,&g_177},{(void*)0,&g_175,&g_175,(void*)0,&g_175,&g_177,&g_176,&g_175,&g_175},{&g_175,&g_175,&g_177,(void*)0,&g_177,&g_175,&g_175,&g_177,&g_175},{&g_176,&g_175,&g_176,(void*)0,&g_177,&g_176,&g_176,&g_176,&g_177},{&g_176,&g_177,&g_177,&g_176,&g_175,&g_176,(void*)0,&g_177,&g_176},{&g_175,&g_177,&g_175,(void*)0,&g_175,&g_175,(void*)0,&g_175,&g_177},{(void*)0,&g_175,&g_175,(void*)0,&g_175,&g_177,&g_176,&g_175,&g_175},{&g_175,&g_175,&g_177,(void*)0,&g_177,&g_175,&g_175,&g_177,&g_175},{&g_176,&g_175,&g_176,(void*)0,&g_177,&g_176,&g_176,&g_176,&g_177},{&g_176,&g_177,&g_177,&g_176,&g_175,&g_176,(void*)0,&g_177,&g_176}};
+static uint8_t **** const g_1547[1][6][2] = {{{&g_1551[1][3],&g_1552[7][4]},{&g_1551[1][3],&g_1551[1][3]},{&g_1552[7][4],&g_1551[1][3]},{&g_1551[1][3],&g_1552[7][4]},{&g_1551[1][3],&g_1551[1][3]},{&g_1552[7][4],&g_1551[1][3]}}};
+static uint8_t **** const *g_1546[5] = {&g_1547[0][2][0],&g_1547[0][2][0],&g_1547[0][2][0],&g_1547[0][2][0],&g_1547[0][2][0]};
+static int8_t ***g_1656 = &g_245;
+static uint16_t g_1766 = 0x2A71L;
+static const uint32_t g_1776 = 4294967288UL;
+static const uint32_t g_1782[6][8][5] = {{{9UL,1UL,0xC7DDDB76L,0x6C0C4151L,0x8031E06CL},{4294967288UL,0x67522ABBL,4294967289UL,9UL,0x6B1862C6L},{4294967289UL,0x035D4646L,0x4BD87A52L,0xF04D3E88L,0x02BA768FL},{0x67522ABBL,1UL,0xFBE5C2AFL,0x09838561L,0x6E51EAD8L},{0x67522ABBL,0x8031E06CL,0xFC56E314L,0x5133D18EL,0xF04D3E88L},{4294967289UL,0xFBE5C2AFL,4294967286UL,4294967295UL,4294967295UL},{4294967288UL,4294967289UL,4294967288UL,0xFC56E314L,0x4BD87A52L},{9UL,0x09838561L,4294967295UL,1UL,3UL}},{{0xD3C5907BL,0x6C0C4151L,4294967289UL,0x8031E06CL,0x035D4646L},{0x6B1862C6L,0x6E51EAD8L,4294967295UL,3UL,0x02BA768FL},{4294967294UL,0xD3C5907BL,4294967288UL,0x67522ABBL,4294967289UL},{0x6C0C4151L,0x8031E06CL,4294967286UL,4294967295UL,0xB9EFEB98L},{8UL,4294967291UL,0xFC56E314L,4294967295UL,0x2B8C1A21L},{4294967291UL,0x6B1862C6L,0xFBE5C2AFL,1UL,0x2B8C1A21L},{9UL,0x1C34F8ADL,0x4BD87A52L,4294967288UL,0xB9EFEB98L},{1UL,4294967288UL,4294967289UL,0xB9EFEB98L,4294967289UL}},{{0xE9241C7AL,0xE9241C7AL,0x6E51EAD8L,1UL,0x09838561L},{4294967288UL,3UL,0x8031E06CL,4294967291UL,0x37358859L},{1UL,4294967295UL,0xD83C2DFAL,1UL,4294967286UL},{0x4478B581L,3UL,0x2B8C1A21L,8UL,0x5A8F52F4L},{0xB9EFEB98L,0xE9241C7AL,0xF04D3E88L,0xC7DDDB76L,8UL},{1UL,1UL,0UL,7UL,0x5133D18EL},{0xF04D3E88L,4294967291UL,0x084A6D3FL,4294967286UL,0x02BA768FL},{0x02BA768FL,0xB3D218BBL,4294967289UL,4294967286UL,0x09838561L}},{{0x2BAF5CEFL,9UL,0xFDF9E1B7L,7UL,0xB3D218BBL},{4294967291UL,4294967295UL,0xC7DDDB76L,0xC7DDDB76L,4294967295UL},{0x37358859L,0x9D243B0BL,4294967295UL,8UL,4294967289UL},{0xFDF9E1B7L,0x02BA768FL,0x9D243B0BL,1UL,0x6B1862C6L},{1UL,0xFBE5C2AFL,0x6B1862C6L,4294967291UL,4294967286UL},{0xFDF9E1B7L,0x2BAF5CEFL,0x084A6D3FL,1UL,0x731D77D9L},{0x37358859L,0x084A6D3FL,0x035D4646L,0xFC56E314L,0x09838561L},{4294967291UL,0xB9EFEB98L,9UL,1UL,0x4478B581L}},{{0x2BAF5CEFL,4294967295UL,4294967291UL,4294967295UL,1UL},{0x02BA768FL,0x8031E06CL,4294967291UL,8UL,0UL},{0xF04D3E88L,0x37358859L,9UL,0x2B8C1A21L,0x6E51EAD8L},{1UL,0xD3C5907BL,0x035D4646L,0xD3C5907BL,1UL},{0xB9EFEB98L,4294967288UL,0x084A6D3FL,4294967286UL,0xE9241C7AL},{0x4478B581L,0x731D77D9L,0x6B1862C6L,4294967295UL,0x09838561L},{1UL,0xFDF9E1B7L,0x9D243B0BL,4294967288UL,0xE9241C7AL},{4294967288UL,4294967295UL,4294967295UL,0x4BD87A52L,1UL}},{{0xE9241C7AL,0xF04D3E88L,0xC7DDDB76L,8UL,0x6E51EAD8L},{0x8031E06CL,0x4478B581L,0xFDF9E1B7L,4294967291UL,0UL},{1UL,7UL,4294967289UL,0x2BAF5CEFL,1UL},{9UL,7UL,0x084A6D3FL,0x5133D18EL,0x4478B581L},{0x731D77D9L,0x4478B581L,0UL,1UL,0x09838561L},{0xFBE5C2AFL,0xF04D3E88L,0xF04D3E88L,0xFBE5C2AFL,0x731D77D9L},{7UL,4294967295UL,0x2B8C1A21L,0xD83C2DFAL,4294967286UL},{0xB3D218BBL,0xFDF9E1B7L,0xD83C2DFAL,8UL,0x6B1862C6L}}};
+static const uint32_t *g_1781 = &g_1782[2][3][4];
+static int8_t g_1857 = 0L;
+static const uint8_t *g_1941 = (void*)0;
+static const uint8_t ** const g_1940[7] = {&g_1941,&g_1941,&g_1941,&g_1941,&g_1941,&g_1941,&g_1941};
+static const uint8_t ** const *g_1939 = &g_1940[2];
+static const uint8_t ** const **g_1938 = &g_1939;
+static const uint8_t ** const ***g_1937 = &g_1938;
+static int16_t g_1961 = (-2L);
+static const int8_t g_2067 = (-1L);
+static const uint32_t ***g_2068[3] = {(void*)0,(void*)0,(void*)0};
+static int8_t g_2147[10] = {0x23L,0x23L,0x23L,0x23L,0x23L,0x23L,0x23L,0x23L,0x23L,0x23L};
+static uint16_t g_2148 = 0x794EL;
+static int16_t g_2207 = 0L;
+
+
+/* --- FORWARD DECLARATIONS --- */
+static uint16_t func_1(void);
+static int8_t func_10(uint32_t p_11);
+static int32_t func_16(int8_t p_17, uint32_t * p_18, uint32_t * p_19, uint16_t p_20, uint32_t p_21);
+static uint32_t * func_22(int16_t p_23, uint32_t p_24, uint32_t * p_25);
+static int32_t func_62(int32_t * p_63, uint8_t p_64);
+static int32_t * func_65(int8_t p_66, uint16_t p_67, uint8_t p_68, int32_t * p_69, uint32_t * p_70);
+static uint8_t * func_71(uint32_t p_72, int8_t p_73);
+static int32_t * func_94(uint32_t * p_95, int32_t p_96, const int32_t p_97, int32_t p_98, int8_t p_99);
+static int8_t func_100(int32_t * p_101, uint8_t p_102, uint8_t p_103, uint32_t p_104);
+static int32_t * func_105(uint32_t p_106);
+
+
+/* --- FUNCTIONS --- */
+/* ------------------------------------------ */
+/*
+ * reads : g_2 g_14 g_15 g_36 g_40 g_43 g_3 g_52 g_46 g_51 g_55 g_56 g_44 g_251 g_143 g_140 g_176 g_705 g_289 g_290 g_297 g_255 g_34 g_131 g_132 g_243 g_347 g_320 g_736 g_294 g_175 g_897 g_905 g_735 g_960 g_969 g_961 g_312 g_1334 g_1132 g_1184 g_1185 g_1099 g_1656 g_1238 g_1548 g_1018 g_1019 g_1254 g_1766 g_1776 g_1857 g_477 g_1298 g_1937 g_1961 g_242 g_1781 g_1782 g_419 g_2068 g_245 g_1938 g_2147 g_2148 g_1333 g_2207
+ * writes: g_3 g_14 g_15 g_34 g_36 g_40 g_52 g_51 g_46 g_255 g_297 g_140 g_312 g_294 g_56 g_44 g_347 g_290 g_897 g_904 g_419 g_251 g_969 g_1334 g_1132 g_1298 g_175 g_1099 g_1055 g_477 g_55 g_1766 g_1781 g_960 g_242 g_961 g_705 g_2068 g_2148 g_2207
+ */
+static uint16_t func_1(void)
+{ /* block id: 0 */
+ int32_t l_38 = 0xCA862934L;
+ int32_t l_1612 = 0xB952CD69L;
+ int32_t l_1634 = 0x1D6D5307L;
+ int16_t l_1658[5][6] = {{0x1999L,0L,0x1999L,0x1999L,0L,0x1999L},{0x1999L,0L,0x1999L,0x1999L,0L,0x0361L},{0x0361L,0x1999L,0x0361L,0x0361L,0x1999L,0x0361L},{0x0361L,0x1999L,0x0361L,0x0361L,0x1999L,0x0361L},{0x0361L,0x1999L,0x0361L,0x0361L,0x1999L,0x0361L}};
+ uint8_t * const ***l_1712 = &g_1295;
+ uint8_t * const ****l_1711[9] = {&l_1712,&l_1712,&l_1712,&l_1712,&l_1712,&l_1712,&l_1712,&l_1712,&l_1712};
+ uint8_t **l_1725 = &g_43;
+ int16_t l_1756[10][2] = {{0xB2C0L,(-1L)},{(-1L),0xB2C0L},{(-1L),(-1L)},{0xB2C0L,(-1L)},{(-1L),0xB2C0L},{(-1L),(-1L)},{0xB2C0L,(-1L)},{(-1L),0xB2C0L},{(-1L),(-1L)},{0xB2C0L,(-1L)}};
+ int32_t l_1763 = (-8L);
+ uint32_t *l_1783 = &g_14[1];
+ int32_t ***l_1785 = &g_961;
+ uint32_t *****l_1788 = (void*)0;
+ uint8_t l_1831 = 0x9CL;
+ uint8_t *l_1877 = &g_40[0];
+ uint32_t l_2046 = 18446744073709551609UL;
+ int8_t l_2047 = 1L;
+ uint32_t l_2048 = 2UL;
+ int32_t l_2056 = 1L;
+ int32_t l_2058 = 0L;
+ int32_t l_2072 = 9L;
+ uint32_t l_2099 = 4UL;
+ uint32_t l_2116 = 4UL;
+ uint32_t l_2184 = 0xE4A882E7L;
+ int16_t **l_2189[6][6][7] = {{{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{(void*)0,&g_289,&g_289,(void*)0,(void*)0,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{(void*)0,&g_289,&g_289,&g_289,(void*)0,&g_289,(void*)0},{&g_289,(void*)0,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,(void*)0,&g_289,(void*)0,&g_289,&g_289,&g_289}},{{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,(void*)0,(void*)0}},{{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{(void*)0,(void*)0,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,(void*)0,&g_289,&g_289,&g_289},{(void*)0,&g_289,&g_289,&g_289,&g_289,(void*)0,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,(void*)0,&g_289,&g_289,(void*)0}},{{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,(void*)0,&g_289},{&g_289,(void*)0,(void*)0,(void*)0,(void*)0,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,(void*)0,&g_289},{&g_289,&g_289,(void*)0,&g_289,(void*)0,&g_289,&g_289}},{{&g_289,&g_289,&g_289,(void*)0,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,(void*)0},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,(void*)0,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,(void*)0,(void*)0,&g_289,&g_289,&g_289,&g_289}},{{&g_289,(void*)0,&g_289,&g_289,&g_289,&g_289,&g_289},{&g_289,&g_289,(void*)0,&g_289,&g_289,(void*)0,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{(void*)0,&g_289,&g_289,(void*)0,(void*)0,&g_289,&g_289},{&g_289,&g_289,&g_289,&g_289,&g_289,&g_289,&g_289},{(void*)0,&g_289,&g_289,&g_289,(void*)0,&g_289,(void*)0}}};
+ int16_t ***l_2188 = &l_2189[0][5][4];
+ int16_t ****l_2187[1];
+ int i, j, k;
+ for (i = 0; i < 1; i++)
+ l_2187[i] = &l_2188;
+lbl_2208:
+ for (g_3 = 0; (g_3 <= 0); g_3 += 1)
+ { /* block id: 3 */
+ uint32_t *l_12 = (void*)0;
+ uint32_t *l_13[2][9][7] = {{{&g_14[4],&g_14[2],&g_14[1],&g_14[1],&g_14[1],(void*)0,&g_14[4]},{(void*)0,&g_14[1],&g_14[3],&g_14[1],&g_14[1],&g_14[3],&g_14[1]},{&g_14[4],&g_14[2],&g_14[1],&g_14[1],&g_14[1],(void*)0,&g_14[4]},{(void*)0,&g_14[1],&g_14[3],&g_14[1],&g_14[1],&g_14[3],&g_14[1]},{&g_14[4],&g_14[2],&g_14[1],&g_14[1],&g_14[1],(void*)0,&g_14[4]},{(void*)0,&g_14[1],&g_14[3],&g_14[1],&g_14[1],&g_14[3],&g_14[1]},{&g_14[4],&g_14[2],&g_14[1],&g_14[1],&g_14[1],(void*)0,&g_14[4]},{(void*)0,&g_14[1],&g_14[3],&g_14[1],&g_14[1],&g_14[3],&g_14[1]},{&g_14[4],&g_14[2],&g_14[1],&g_14[1],&g_14[1],(void*)0,&g_14[4]}},{{(void*)0,&g_14[1],&g_14[3],&g_14[1],&g_14[1],&g_14[3],&g_14[1]},{&g_14[4],&g_14[2],&g_14[1],&g_14[1],&g_14[1],(void*)0,&g_14[4]},{(void*)0,&g_14[1],&g_14[3],&g_14[1],(void*)0,&g_14[1],&g_14[0]},{&g_14[1],&g_14[3],&g_14[1],(void*)0,&g_14[4],&g_14[1],&g_14[1]},{&g_14[1],&g_14[0],&g_14[1],(void*)0,(void*)0,&g_14[1],&g_14[0]},{&g_14[1],&g_14[3],&g_14[1],(void*)0,&g_14[4],&g_14[1],&g_14[1]},{&g_14[1],&g_14[0],&g_14[1],(void*)0,(void*)0,&g_14[1],&g_14[0]},{&g_14[1],&g_14[3],&g_14[1],(void*)0,&g_14[4],&g_14[1],&g_14[1]},{&g_14[1],&g_14[0],&g_14[1],(void*)0,(void*)0,&g_14[1],&g_14[0]}}};
+ int8_t *l_35 = &g_36;
+ int32_t l_37 = 0x129EC6EAL;
+ uint8_t *l_39 = &g_40[1];
+ uint32_t l_1611 = 1UL;
+ const int16_t l_1613 = (-7L);
+ int32_t l_1616 = 0xF7091F80L;
+ int32_t l_1618 = 0x81A177EAL;
+ int32_t l_1623 = (-3L);
+ int8_t ***l_1657 = &g_245;
+ int i, j, k;
+ if ((((((safe_mul_func_int8_t_s_s(((safe_div_func_uint8_t_u_u(((safe_mod_func_int8_t_s_s(func_10((((g_15 &= (g_14[4] ^= g_2[1][0])) == func_16(g_2[2][0], func_22((safe_div_func_int8_t_s_s((safe_mul_func_int16_t_s_s(((safe_div_func_int32_t_s_s((safe_rshift_func_uint8_t_u_s((g_34 = 1UL), ((*l_35) ^= 0x4DL))), l_37)) == (((((*l_39) = l_38) , (--(*l_39))) >= l_37) ^ 0UL)), ((void*)0 == g_43))), g_3)), l_38, l_13[1][1][2]), g_55, l_37, g_56)) >= l_37)), l_38)) == 0x3C9EL), l_38)) , 0xBCL), l_1611)) | l_1612) == 1UL) < l_1613) == 0x39F7L))
+ { /* block id: 771 */
+ int32_t *l_1614 = &g_1055;
+ if (l_1613)
+ break;
+ (**g_960) = l_1614;
+ if (l_1611)
+ continue;
+ }
+ else
+ { /* block id: 775 */
+ int32_t *l_1615 = &g_51[1][6][2];
+ int32_t *l_1617 = &g_297[1];
+ int32_t *l_1619 = &l_1616;
+ int32_t *l_1620 = (void*)0;
+ int32_t *l_1621 = &l_1618;
+ int32_t *l_1622 = &g_297[1];
+ int32_t *l_1624 = &g_51[0][3][1];
+ int32_t *l_1625 = &l_37;
+ int32_t *l_1626 = (void*)0;
+ int32_t *l_1627 = &g_1132;
+ int32_t *l_1628 = &g_297[1];
+ int32_t *l_1629 = &l_1618;
+ int32_t *l_1630[9] = {&g_297[0],&g_297[0],&g_297[0],&g_297[0],&g_297[0],&g_297[0],&g_297[0],&g_297[0],&g_297[0]};
+ uint8_t l_1631 = 6UL;
+ int i;
+ --l_1631;
+ return (*l_1617);
+ }
+ l_1634 |= 0xB346B708L;
+ for (g_1298 = 0; (g_1298 <= 0); g_1298 += 1)
+ { /* block id: 782 */
+ uint32_t l_1635 = 0xEF083A2AL;
+ int32_t l_1644 = 0x4F483357L;
+ (*g_143) ^= l_1635;
+ (*g_143) = (safe_mul_func_uint16_t_u_u(((safe_sub_func_int8_t_s_s(((!(l_38 , l_1611)) != (l_1644 &= (safe_lshift_func_int8_t_s_s((safe_add_func_int8_t_s_s(0x2CL, l_1612)), 4)))), (safe_unary_minus_func_uint32_t_u((safe_div_func_int8_t_s_s(((g_320 <= (((l_38 <= (((safe_add_func_int16_t_s_s((safe_sub_func_uint16_t_u_u((l_1618 & (((safe_div_func_uint16_t_u_u((((((safe_rshift_func_int16_t_s_s(0x3853L, l_1635)) >= l_1612) , g_1656) != l_1657) & l_38), 65531UL)) ^ l_1623) && l_1635)), l_1658[1][1])), 0x80FFL)) == 7UL) == (**g_1238))) > 0x43L) || g_14[5])) , 5L), l_1612)))))) > l_1658[1][1]), 0UL));
+ }
+ for (g_1099 = 0; (g_1099 <= 0); g_1099 += 1)