summaryrefslogtreecommitdiffstatshomepage
path: root/linearize.c
AgeCommit message (Expand)AuthorFilesLines
2020-05-21bad-goto: do not linearize if the IR will be invalidLuc Van Oostenryck1-1/+1
2020-03-20teach sparse to linearize __builtin_unreachable()Luc Van Oostenryck1-0/+7
2020-03-20add support for linearization of builtinsLuc Van Oostenryck1-0/+32
2020-03-20add an implicit __builtin_unreachable() for __noreturnLuc Van Oostenryck1-0/+10
2020-03-20add instruction OP_UNREACHLuc Van Oostenryck1-0/+3
2019-09-30Merge branch 'fix-expand-asm' into tipLuc Van Oostenryck1-23/+25
2019-09-30do not linearize invalid expressionLuc Van Oostenryck1-2/+6
2019-09-27asm: fix liveness memory operandLuc Van Oostenryck1-0/+1
2019-09-27asm: linearization of output memory operands is differentLuc Van Oostenryck1-4/+9
2019-09-27asm: keep using struct asm_operand during linearizationLuc Van Oostenryck1-15/+10
2019-09-27asm: use a specific struct for asm operandsLuc Van Oostenryck1-9/+10
2018-12-21remove unused regno()Luc Van Oostenryck1-8/+0
2018-12-19allocate BBs after the guardsLuc Van Oostenryck1-1/+3
2018-12-19remove unused arg in add_branch()Luc Van Oostenryck1-4/+4
2018-09-08fix linearization of non-constant switch-casesLuc Van Oostenryck1-2/+5
2018-09-06Merge branches 'missing-return' and 'fix-logical-phi' into tipLuc Van Oostenryck1-52/+89
2018-09-06fix linearization of nested logical exprLuc Van Oostenryck1-18/+31
2018-09-06fix ordering of phi-node operandLuc Van Oostenryck1-2/+2
2018-09-06return nothing only in void functionsLuc Van Oostenryck1-3/+3
2018-09-06use a temp var for the return type/symbolLuc Van Oostenryck1-1/+2
2018-09-06use UNDEF for missing returnsLuc Van Oostenryck1-0/+8
2018-09-06extract add_return() from linearize_return()Luc Van Oostenryck1-11/+16
2018-09-06the return BB is never terminatedLuc Van Oostenryck1-8/+7
2018-09-06there is always an active BB after linearize_fn_statement()Luc Van Oostenryck1-2/+2
2018-09-06specialize linearize_compound_statement()Luc Van Oostenryck1-10/+16
2018-09-06topasm: top-level asm is specialLuc Van Oostenryck1-2/+6
2018-09-05use a temp var for function's upper-level statementLuc Van Oostenryck1-2/+3
2018-09-01Merge branch 'dead-switch' into tipLuc Van Oostenryck1-5/+6
2018-09-01fix linearization of unreachable switch (with reachable label).Luc Van Oostenryck1-5/+6
2018-08-31Merge branch 'opcode' into tipLuc Van Oostenryck1-6/+2
2018-08-25fix: do not optimize away accesses to volatile bitfieldsLuc Van Oostenryck1-2/+2
2018-08-25add a flag for volatile memopsLuc Van Oostenryck1-0/+2
2018-08-25symaddr: s/insn->symbol/insn->src/Luc Van Oostenryck1-6/+2
2018-08-25Merge branch 'ssa' into tipLuc Van Oostenryck1-0/+45
2018-08-07fix bad indentation in linearize_inc_dec()Luc Van Oostenryck1-1/+1
2018-08-07fix instruction size & type in linearize_inc_dec()Luc Van Oostenryck1-1/+5
2018-08-07put back the bitfield base type into struct access_dataLuc Van Oostenryck1-5/+7
2018-08-07expand linearize_position() into linearize_initializer()Luc Van Oostenryck1-9/+2
2018-08-06limit the mask used for bitfield insertionLuc Van Oostenryck1-1/+2
2018-08-06cast: fix warning position in cast_pseudo()Luc Van Oostenryck1-2/+3
2018-08-06boolean conversion of boolean value is a no-opLuc Van Oostenryck1-0/+2
2018-08-06simplify linearize_logical()Luc Van Oostenryck1-27/+14
2018-08-06expand linearize_conditional() into linearize_logical()Luc Van Oostenryck1-17/+47
2018-08-06fix linearize_conditional() for logical opsLuc Van Oostenryck1-4/+13
2018-08-06conditional branches can't accept arbitrary expressionsLuc Van Oostenryck1-1/+1
2018-08-06protect add_convert_to_bool() against bad types / invalid expressionsLuc Van Oostenryck1-0/+2
2018-07-25Merge branch 'optim-cast' into tipLuc Van Oostenryck1-17/+33
2018-07-25Merge branch 'optim-shift' into tipLuc Van Oostenryck1-0/+19
2018-07-24use "%Le" to display floatsLuc Van Oostenryck1-2/+2
2018-07-23bitfield: extract linearize_bitfield_insert()Luc Van Oostenryck1-11/+19
2018-07-23bitfield: extract linearize_bitfield_extract()Luc Van Oostenryck1-6/+14
2018-07-21big-shift: mark out-of-range OP_{ASR,LSR,SHL} as taintedLuc Van Oostenryck1-0/+19
2018-07-13remove obsolete comment: /* Dummy pseudo allocator */Luc Van Oostenryck1-1/+0
2018-07-13no need to assign ad->type for EXPR_POSLuc Van Oostenryck1-1/+0
2018-07-13remove unused struct access_data::posLuc Van Oostenryck1-4/+0
2018-07-13remove unused finish_address_gen()Luc Van Oostenryck1-10/+0
2018-07-01add insert_phi_node()Luc Van Oostenryck1-0/+36
2018-07-01add PSEUDO_UNDEF & undef_pseudo()Luc Van Oostenryck1-0/+9
2018-06-28bool: remove OP_{AND,OR}_BOOL instructionsLuc Van Oostenryck1-2/+0
2018-06-28bool: generate plain OP_{AND,OR} instead of OP_{AND,OR}_BOOLLuc Van Oostenryck1-1/+1
2018-06-28bool: fix missing boolean context for floatsLuc Van Oostenryck1-2/+7
2018-06-23cast: keep instruction sizes consistentLuc Van Oostenryck1-1/+11
2018-06-23cast: do not try to linearize illegal castsLuc Van Oostenryck1-0/+2
2018-06-23cast: accept null castsLuc Van Oostenryck1-0/+6
2018-06-23cast: specialize integer castsLuc Van Oostenryck1-11/+16
2018-06-23cast: make casts from pointer always size preservingLuc Van Oostenryck1-0/+2
2018-06-23cast: add support for -Wpointer-to-int-castLuc Van Oostenryck1-0/+5
2018-06-23cast: specialize cast from pointersLuc Van Oostenryck1-0/+7
2018-06-23cast: temporary simplify handling cast to/from void*Luc Van Oostenryck1-4/+15
2018-06-23cast: make pointer casts always size preservingLuc Van Oostenryck1-0/+2
2018-06-23cast: specialize casts from unsigned to pointersLuc Van Oostenryck1-1/+21
2018-06-23cast: specialize floats to integer conversionLuc Van Oostenryck1-0/+5
2018-06-23cast: handle NO-OP castsLuc Van Oostenryck1-0/+8
2018-06-23cast: specialize FPCAST into [USF]CVTFLuc Van Oostenryck1-3/+15
2018-06-23cast: prepare finer grained cast instructionsLuc Van Oostenryck1-15/+63
2018-06-22rename add_uniop() to add_unop()Luc Van Oostenryck1-3/+3
2018-06-22add_uniop() should take a type, not an expressionLuc Van Oostenryck1-5/+6
2018-05-26context: __context__(...) expect a constant expressionLuc Van Oostenryck1-5/+1
2018-05-06fix comment about PSEUDO_SYM usageLuc Van Oostenryck1-1/+1
2018-03-18avoid deadborn loads & storesLuc Van Oostenryck1-1/+11
2018-03-18fix-return: remove special case for single returnLuc Van Oostenryck1-6/+0
2018-03-18defer initialization of bb::contextLuc Van Oostenryck1-1/+0
2018-03-18small code reorg of add_store()Luc Van Oostenryck1-8/+9
2018-03-18extract alloc_phisrc() from alloc_phi()Luc Van Oostenryck1-10/+16
2018-03-18show_label: add (and use) show_label()Luc Van Oostenryck1-16/+25
2018-03-01IR: let OP_COMPUTEGOTO use .src instead of .targetLuc Van Oostenryck1-2/+2
2018-03-01IR: remove never-generated instructionsLuc Van Oostenryck1-8/+0
2018-03-01IR: remove now unused OP_LNOP & OP_SNOPLuc Van Oostenryck1-4/+2
2018-02-24move the optimization loop in its own fileLuc Van Oostenryck1-62/+2
2018-02-20ban use of 'true' or 'false'Luc Van Oostenryck1-6/+6
2018-02-20no need for signed & unsigned multiplicationLuc Van Oostenryck1-5/+4
2018-02-17rename base_type() to bitfield_base_type()Luc Van Oostenryck1-5/+5
2018-02-17let struct access_data use a single typeLuc Van Oostenryck1-23/+21
2018-02-17use show_pseudo() for OP_SYMADDR's symbolLuc Van Oostenryck1-16/+3
2018-02-17show_pseudo(): protect against NULL ->symLuc Van Oostenryck1-0/+4
2018-02-08Merge branches 'cse-setfval' and 'extract-eval' into tipLuc Van Oostenryck1-3/+1
2018-01-31remove warning "call with no type"Luc Van Oostenryck1-3/+1
2018-01-08add OP_SETFVALLuc Van Oostenryck1-5/+13
2018-01-07cleanup: make some functions staticLuc Van Oostenryck1-6/+6
2017-12-28fix crash on bad expression in linearize_switch()Luc Van Oostenryck1-0/+2
2017-12-21fix linearize (*fun)()Luc Van Oostenryck1-7/+3
2017-12-21simplify linearize_call_expression()Luc Van Oostenryck1-8/+3
2017-11-18add support of floating-point specific arithmetic opsLuc Van Oostenryck1-4/+15
2017-11-18fix support of floating-point compareLuc Van Oostenryck1-2/+19
2017-11-18fix linearize_inc_dec() with floatsLuc Van Oostenryck1-2/+16
2017-11-17add support for wider type in switch-caseLuc Van Oostenryck1-4/+4
2017-11-16give a type to OP_SWITCHsLuc Van Oostenryck1-2/+3
2017-11-16give a type to OP_SELs, alwaysLuc Van Oostenryck1-1/+1
2017-11-16give a type to OP_PHISOURCEsLuc Van Oostenryck1-9/+7
2017-11-16give a type to all function argumentsLuc Van Oostenryck1-6/+7
2017-11-16fix usage of inlined callsLuc Van Oostenryck1-1/+1
2017-11-16don't output value of anonymous symbol's pointerLuc Van Oostenryck1-2/+2
2017-11-16show OP_PHI without VOIDLuc Van Oostenryck1-0/+2
2017-11-13Merge branch 'dump-ir' into tipLuc Van Oostenryck1-5/+7
2017-11-13dump-ir: activate -fdump-ir=mem2regLuc Van Oostenryck1-0/+2
2017-11-13dump-ir: make it more flexibleLuc Van Oostenryck1-1/+1
2017-11-13dump-ir: rename -fdump-linearize to -fdump-irLuc Van Oostenryck1-1/+1
2017-11-13dump-ir: saner use of fdump_linearizeLuc Van Oostenryck1-4/+1
2017-11-13dump-ir: allow to skip the optimization pass(es)Luc Van Oostenryck1-0/+2
2017-11-12dump-ir: activate/deactive pass 'mem2reg'Luc Van Oostenryck1-1/+2
2017-09-17use a specific struct for asm operandsLuc Van Oostenryck1-38/+4
2017-07-31fix crash with sym->bb_target == NULLLuc Van Oostenryck1-1/+4
2017-07-31fix crash when ep->active is NULLLuc Van Oostenryck1-2/+7
2017-07-31fix ptrlist corruption while killing unreachable BBsLuc Van Oostenryck1-3/+0
2017-05-19Merge branches 'dump-macros-v2', 'fix-predefined-size', 'fix-bool-context', '...v0.5.1-rc1Luc Van Oostenryck1-19/+67
2017-05-19add support for a new flag: -fdump-linearize[=only]Luc Van Oostenryck1-0/+6
2017-05-19remove origval from struct access_dataLuc Van Oostenryck1-6/+0
2017-05-19remove alignment from struct access_dataLuc Van Oostenryck1-2/+1
2017-05-19fix implicit zero initializer.Luc Van Oostenryck1-0/+15
2017-05-19remove bit_size & bit_offset from struct access_dataLuc Van Oostenryck1-8/+8
2017-05-19fix: kill old branch in insert_branch()Luc Van Oostenryck1-1/+2
2017-05-12fix boolean context for OP_AND_BOOL & OP_OR_BOOLLuc Van Oostenryck1-2/+35
2017-05-12fix: kill unreachable BBs after killing a childLuc Van Oostenryck1-1/+4
2017-04-30Merge branches 'sent/float-expand-v2', 'sent/fix-kill-ttsb-v2', 'sent/fix-con...Luc Van Oostenryck1-0/+2
2017-03-31avoid crash with test-linearize -vvLuc Van Oostenryck1-0/+2
2017-03-27fix cast to pointer to floating-pointLuc Van Oostenryck1-2/+1
2017-03-06use VOID instead of directly using &void_pseudoLuc Van Oostenryck1-1/+1
2017-03-06split OP_BR between unconditional & conditional: OP_CBRLuc Van Oostenryck1-6/+8
2017-03-04fix size of loaded bitfieldsLuc Van Oostenryck1-1/+3
2017-02-13fix cast's target type infoLuc Van Oostenryck1-2/+2
2017-02-13fix value of label statementLuc Van Oostenryck1-2/+1
2017-02-13fix typing error in compound assignmentLuc Van Oostenryck1-4/+6
2017-02-13OP_SWITCH should use 'insn->cond' instead of 'insn->target'Luc Van Oostenryck1-1/+1
2017-02-13give comparable label's names to basic blocksLuc Van Oostenryck1-14/+16
2017-02-13fix discarded label statementLuc Van Oostenryck1-1/+1
2017-01-27linearize: Emit C99 declarations correctlyEmily Maier1-0/+4
2013-05-27Fix result type of relational and logical operatorsXi Wang1-2/+2
2012-02-04sparse, llvm: Make function declaration accessible to backendLinus Torvalds1-0/+8
2011-08-27Make 'linearize_return()' helper functionLinus Torvalds1-22/+26
2011-08-27Make 'linearize_switch()' helper functionLinus Torvalds1-61/+65
2011-08-27Make 'linearize_iterator()' helper functionLinus Torvalds1-40/+45
2011-04-26use ARRAY_SIZE() when possible (continued)Jan Pokorný1-1/+1
2010-03-28Fix incorrect linearization of "x && y && z"Daniel De Graaf1-1/+3
2009-07-29linearize.h: sanitize headerKamil Dudka1-3/+3
2008-12-24Revert the context tracking codeJohannes Berg1-15/+16
2008-12-18Add type information to struct instruction.David Given1-1/+3
2008-04-24fix bug in context tracking codeJohannes Berg1-1/+0
2008-04-24Fix cast instruction generationLinus Torvalds1-3/+3
2008-04-21sparse: simple conditional context trackingJohannes Berg1-16/+6
2008-04-21make sparse keep its promise about context trackingJohannes Berg1-0/+10
2007-07-10fix handling of address_space in casts and assignmentsAl Viro1-0/+1
2007-05-22Improved graph generation using subgraph clusters for functionsDan Sheridan1-0/+1
2007-05-22Use %td when printing a ptrdiff_t to avoid problems on 64-bit platformsJosh Triplett1-1/+1
2007-05-22Revert unintentional inclusion of warning fix in previous commit.Josh Triplett1-1/+1
2007-05-22Add test case for -Wno-old-initializerJosh Triplett1-1/+1
2007-04-20Fix the annotated inline call positionChristopher Li1-0/+4
2007-03-02Add annotation for inline function call.Christopher Li1-7/+37
2007-02-28Disable liveness "dead" instruction by default.Christopher Li1-1/+2
2007-02-26Coding style fix: use parentheses with sizeofJosh Triplett1-1/+1
2007-02-26Fix core dump on huge switchChristopher Li1-1/+4
2007-02-22Fix core dump on anonymous symbol.Christopher Li1-8/+10
2007-01-27Coding style fix: in a pointer type, * goes with the name, not the type.Josh Triplett1-2/+2
2007-01-16Add instruction to pseudo user tracking.Christopher Li1-35/+37
2007-01-16Change the symbol access list to a pseudo listChristopher Li1-5/+5
2006-08-30[PATCH] Parse and track multiple contexts by expressionJosh Triplett1-21/+28
2005-12-31Make local declarations be statements of their ownLinus Torvalds1-7/+15
2005-11-21[PATCH] Add a new opcode: OP_COPY.Luc Van Oostenryck1-0/+5
2005-08-15Clean up iterator handlingLinus Torvalds1-2/+3
2005-06-27[PATCH] makes some needlessly global code staticLuc Van Oostenryck1-6/+6
2005-06-26[PATCH] avoid segfault in add_asm_output() after a parse error in asm statementLuc Van Oostenryck1-1/+1
2005-06-26[PATCH] avoid segafult after parse errors in castsLuc Van Oostenryck1-0/+3
2005-06-26[PATCH] avoid segfault after parse errors in assignementsLuc Van Oostenryck1-0/+3
2005-06-26[PATCH] avoid segfault in linearize_asm_statement() after a parse error in as...Luc Van Oostenryck1-1/+1
2005-06-26[PATCH] Avoid segfault when code is present after a goto statementLuc Van Oostenryck1-2/+2
2005-06-21Be more careful about linearizing conditionalsLinus Torvalds1-3/+7
2005-06-20[PATCH] segfault on bad ternary conditionalLuc Van Oostenryck1-1/+5
2005-06-19Fix SIGSEGV on assignment to bad left side.Linus Torvalds1-2/+2
2005-04-07Add support for context checking functions.Linus Torvalds1-5/+13
2005-04-07Avoid SIGSEGV when linearizing bad expressions.Linus Torvalds1-1/+1
2005-04-07Make each instruction have a position of its own.Linus Torvalds1-0/+6
2005-04-07Add compile-time "range-check" infrastructure to sparseLinus Torvalds1-3/+21
2005-04-07Split OP_CAST into signed, unsigned and FP casts.Linus Torvalds1-0/+8
2005-04-07Make the example code generator do something half-way saneLinus Torvalds1-0/+1
2005-04-07Split the binops where signedness matters into unsigned and signed.Linus Torvalds1-14/+34
2005-04-07Make linearizer able to handle assignment ops where theLinus Torvalds1-41/+50
2005-04-07Linearize EXPR_POS initializers more carefully: they canLinus Torvalds1-4/+2
2005-04-07Get comparison sizes right.Linus Torvalds1-2/+2
2005-04-07Split OP_SETVAL into OP_SETVAL (fp expressions and labels) and OP_SYMADDRLinus Torvalds1-24/+29
2005-04-07Save off the asm parameter name too.Linus Torvalds1-14/+38
2005-04-07Make asm linearization not drop the constraints.Linus Torvalds1-25/+53