Page MenuHomePhabricator

Petar.Avramovic (Petar Avramovic)
User

Projects

User does not belong to any projects.

User Details

User Since
Feb 21 2018, 6:39 AM (81 w, 6 d)

Recent Activity

Thu, Sep 12

Petar.Avramovic committed rGff6ac1eb5f30: [MIPS GlobalISel] Select indirect branch (authored by Petar.Avramovic).
[MIPS GlobalISel] Select indirect branch
Thu, Sep 12, 4:45 AM
Petar.Avramovic committed rL371730: [MIPS GlobalISel] Select indirect branch.
[MIPS GlobalISel] Select indirect branch
Thu, Sep 12, 4:44 AM
Petar.Avramovic closed D67441: [MIPS GlobalISel] Select indirect branch.
Thu, Sep 12, 4:44 AM · Restricted Project
Petar.Avramovic committed rG646e1f7b7fa3: [MIPS GlobalISel] Lower G_DYN_STACKALLOC (authored by Petar.Avramovic).
[MIPS GlobalISel] Lower G_DYN_STACKALLOC
Thu, Sep 12, 4:40 AM
Petar.Avramovic committed rL371728: [MIPS GlobalISel] Lower G_DYN_STACKALLOC.
[MIPS GlobalISel] Lower G_DYN_STACKALLOC
Thu, Sep 12, 4:40 AM
Petar.Avramovic closed D67440: [MIPS GlobalISel] Lower G_DYN_STACKALLOC.
Thu, Sep 12, 4:39 AM · Restricted Project
Petar.Avramovic committed rG75e43a607c8b: [MIPS GlobalISel] Select G_IMPLICIT_DEF (authored by Petar.Avramovic).
[MIPS GlobalISel] Select G_IMPLICIT_DEF
Thu, Sep 12, 4:32 AM
Petar.Avramovic committed rL371727: [MIPS GlobalISel] Select G_IMPLICIT_DEF.
[MIPS GlobalISel] Select G_IMPLICIT_DEF
Thu, Sep 12, 4:31 AM
Petar.Avramovic closed D67439: [MIPS GlobalISel] Select G_IMPLICIT_DEF.
Thu, Sep 12, 4:31 AM · Restricted Project

Wed, Sep 11

Petar.Avramovic created D67440: [MIPS GlobalISel] Lower G_DYN_STACKALLOC.
Wed, Sep 11, 5:56 AM · Restricted Project
Petar.Avramovic created D67439: [MIPS GlobalISel] Select G_IMPLICIT_DEF.
Wed, Sep 11, 5:56 AM · Restricted Project
Petar.Avramovic created D67441: [MIPS GlobalISel] Select indirect branch.
Wed, Sep 11, 5:56 AM · Restricted Project

Mon, Sep 9

Petar.Avramovic accepted D67320: [mips] Fix decoding of microMIPS JALX instruction.

LGTM.

Mon, Sep 9, 8:12 AM · Restricted Project

Thu, Sep 5

Petar.Avramovic committed rGa4bfc8dfdaef: [MIPS GlobalISel] Select G_FENCE (authored by Petar.Avramovic).
[MIPS GlobalISel] Select G_FENCE
Thu, Sep 5, 4:20 AM
Petar.Avramovic committed rL371056: [MIPS GlobalISel] Select G_FENCE.
[MIPS GlobalISel] Select G_FENCE
Thu, Sep 5, 4:20 AM
Petar.Avramovic closed D67181: [MIPS GlobalISel] Select G_FENCE.
Thu, Sep 5, 4:20 AM · Restricted Project
Petar.Avramovic committed rGf5c7fe0795c8: [MIPS GlobalISel] Select llvm.trap intrinsic (authored by Petar.Avramovic).
[MIPS GlobalISel] Select llvm.trap intrinsic
Thu, Sep 5, 4:16 AM
Petar.Avramovic committed rL371055: [MIPS GlobalISel] Select llvm.trap intrinsic.
[MIPS GlobalISel] Select llvm.trap intrinsic
Thu, Sep 5, 4:15 AM
Petar.Avramovic closed D67180: [MIPS GlobalISel] Select llvm.trap intrinsic.
Thu, Sep 5, 4:15 AM · Restricted Project
Petar.Avramovic committed rGd2574d79b64d: [MIPS GlobalISel] Lower SRet pointer arguments (authored by Petar.Avramovic).
[MIPS GlobalISel] Lower SRet pointer arguments
Thu, Sep 5, 4:12 AM
Petar.Avramovic committed rL371054: [MIPS GlobalISel] Lower SRet pointer arguments.
[MIPS GlobalISel] Lower SRet pointer arguments
Thu, Sep 5, 4:10 AM
Petar.Avramovic closed D67179: [MIPS GlobalISel] Lower SRet pointer arguments.
Thu, Sep 5, 4:10 AM · Restricted Project

Wed, Sep 4

Petar.Avramovic created D67181: [MIPS GlobalISel] Select G_FENCE.
Wed, Sep 4, 8:20 AM · Restricted Project
Petar.Avramovic created D67180: [MIPS GlobalISel] Select llvm.trap intrinsic.
Wed, Sep 4, 8:20 AM · Restricted Project
Petar.Avramovic created D67179: [MIPS GlobalISel] Lower SRet pointer arguments.
Wed, Sep 4, 8:17 AM · Restricted Project

Mon, Sep 2

Petar.Avramovic accepted D67014: [mips] Switch to the `.text` section after emitting asm file preamble.

LGTM.

Mon, Sep 2, 9:55 AM · Restricted Project

Thu, Aug 29

Petar.Avramovic committed rGe96892a8aa4d: [MIPS GlobalISel] Lower uitofp (authored by Petar.Avramovic).
[MIPS GlobalISel] Lower uitofp
Thu, Aug 29, 10:53 PM
Petar.Avramovic committed rL370432: [MIPS GlobalISel] Lower uitofp.
[MIPS GlobalISel] Lower uitofp
Thu, Aug 29, 10:50 PM
Petar.Avramovic closed D66930: [MIPS GlobalISel] Lower uitofp.
Thu, Aug 29, 10:50 PM · Restricted Project
Petar.Avramovic committed rG6412b56513a3: [MIPS GlobalISel] Lower fptoui (authored by Petar.Avramovic).
[MIPS GlobalISel] Lower fptoui
Thu, Aug 29, 10:47 PM
Petar.Avramovic committed rL370431: [MIPS GlobalISel] Lower fptoui.
[MIPS GlobalISel] Lower fptoui
Thu, Aug 29, 10:47 PM
Petar.Avramovic closed D66929: [MIPS GlobalISel] Lower fptoui.
Thu, Aug 29, 10:47 PM · Restricted Project
Petar.Avramovic accepted D66894: [mips] Fix expanding `lw/sw $reg1, symbol($reg2)` instruction.

LGTM.

Thu, Aug 29, 3:38 AM · Restricted Project
Petar.Avramovic added a comment to D66930: [MIPS GlobalISel] Lower uitofp.

Algorithm is similar to the one SDAG uses in SelectionDAGLegalize::ExpandLegalINT_TO_FP
The difference is that here we use BuildPair instead of sequence of two i32 stores followed by f64 load since it results in one instruction less.

Thu, Aug 29, 1:07 AM · Restricted Project
Petar.Avramovic created D66930: [MIPS GlobalISel] Lower uitofp.
Thu, Aug 29, 1:02 AM · Restricted Project
Petar.Avramovic created D66929: [MIPS GlobalISel] Lower fptoui.
Thu, Aug 29, 1:02 AM · Restricted Project

Wed, Aug 28

Petar.Avramovic added a comment to D66228: [mips] Fix 64-bit address loading in case of applying 32-bit mask to the result.

LGTM. Let's wait for @sdardis.

Wed, Aug 28, 4:22 AM · Restricted Project

Tue, Aug 27

Petar.Avramovic added a comment to D66805: [MIPS] For vectors, select `add %x, C` as `sub %x, -C` if it results in inline immediate.

Oh, I see. Then we have to undo combines here. Let's what for Simon.

Tue, Aug 27, 9:45 AM · Restricted Project
Petar.Avramovic added a comment to D66805: [MIPS] For vectors, select `add %x, C` as `sub %x, -C` if it results in inline immediate.

This patch targets very specific values(1,-1) but there are more. The trick for D62341 is that msa vector add/sub imm accept 5 bit unsigned imm, so it is ok to switch from add imm to sub imm (also sub to add) if it changes imm form negative to positive. I think it is cleanest to have some hook and ask target if it would like to transform sub into add (add to sub) with imm.

Tue, Aug 27, 9:13 AM · Restricted Project
Petar.Avramovic committed rL370067: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .
[MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR
Tue, Aug 27, 7:55 AM
Petar.Avramovic committed rL370064: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC.
[GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC
Tue, Aug 27, 7:47 AM
Petar.Avramovic committed rG4a2a65328893: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR (authored by Petar.Avramovic).
[MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR
Tue, Aug 27, 7:43 AM
Petar.Avramovic closed D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .
Tue, Aug 27, 7:42 AM · Restricted Project
Petar.Avramovic committed rGa393238422ec: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC (authored by Petar.Avramovic).
[GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC
Tue, Aug 27, 7:33 AM
Petar.Avramovic closed D66589: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC.
Tue, Aug 27, 7:33 AM · Restricted Project
Petar.Avramovic committed rL370062: [GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG.
[GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG
Tue, Aug 27, 7:33 AM
Petar.Avramovic committed rGd568ed40e0cb: [GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG (authored by Petar.Avramovic).
[GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG
Tue, Aug 27, 7:25 AM
Petar.Avramovic closed D66587: [GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG.
Tue, Aug 27, 7:25 AM · Restricted Project
Petar.Avramovic accepted D66771: [mips] Use less registers to load address of TargetExternalSymbol.

LGTM.

Tue, Aug 27, 6:37 AM · Restricted Project
Petar.Avramovic added a comment to D66678: [GlobalISel] Replace hard coded dynamic alloca handling with G_DYN_STACKALLOC.

One nit, inlined, other then that looks good.

Tue, Aug 27, 5:56 AM · Restricted Project

Thu, Aug 22

Petar.Avramovic accepted D66553: [mips] Reduce number of instructions used for loading a global symbol's value.

LGTM.

Thu, Aug 22, 9:05 AM · Restricted Project
Petar.Avramovic accepted D66552: [mips] Do not include offset into `%got` expression for global symbols.

LGTM.

Thu, Aug 22, 9:05 AM · Restricted Project
Petar.Avramovic added a child revision for D66589: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC: D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .
Thu, Aug 22, 6:32 AM · Restricted Project
Petar.Avramovic added a parent revision for D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR : D66589: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC.
Thu, Aug 22, 6:32 AM · Restricted Project
Petar.Avramovic added a parent revision for D66589: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC: D66587: [GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG.
Thu, Aug 22, 6:32 AM · Restricted Project
Petar.Avramovic added a child revision for D66587: [GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG: D66589: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC.
Thu, Aug 22, 6:32 AM · Restricted Project
Petar.Avramovic updated the diff for D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .

Split changes to three smaller patches.

Thu, Aug 22, 6:32 AM · Restricted Project
Petar.Avramovic created D66589: [GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC.
Thu, Aug 22, 6:32 AM · Restricted Project
Petar.Avramovic created D66587: [GlobalISel] Fix narrowScalar for shifts to match algorithm from SDAG.
Thu, Aug 22, 6:25 AM · Restricted Project

Wed, Aug 21

Petar.Avramovic added inline comments to D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .
Wed, Aug 21, 10:00 AM · Restricted Project
Petar.Avramovic added inline comments to D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .
Wed, Aug 21, 9:02 AM · Restricted Project
Petar.Avramovic added a comment to D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .

@aemerson @arsenm
test-suite/SingleSource/UnitTests/2003-05-31-LongShifts.c used to give bad result in high bits for some values,
changes to narrow scalar for G_SHL, G_ASHR and G_LSHR fixes that on MIPS32. Does it work for you?

Wed, Aug 21, 7:05 AM · Restricted Project
Petar.Avramovic created D66533: [MIPS GlobalISel] ClampScalar G_SHL, G_ASHR and G_LSHR .
Wed, Aug 21, 7:02 AM · Restricted Project
Petar.Avramovic added a comment to D61787: [GlobalISel Legalizer] Improve artifact combiner.

I think it’s okay not to combine legal artifacts

Often they get combined before even asking if they are legal or not, there is no strict agreement on what should be combined or not it's kind of random and depends on the order we attempt combines.

Therefore, I don’t think adding more combines would improve the legalizer. We should probably work on the current legalization strategy first before doing something like that. What do you think?

I see two routes atm, one is this patch and no more combines, other is D65894 as it deals with combining non-legal artifacts, and to catch combines of legal artifacts we could add more combines, like D62338 and for example add combine for G_MERGE, similar to G_TRUNC, by inspecting uses of G_MERGE def operands in hope to find G_UNMERGE and perform combine from that G_UNMERGE. With such combines it is possible to visit def before all it uses have been visited and tracking of dead instructions becomes a little difficult. It all comes down to how we menage Observer lists that hold instructions/artifacts.
If we want to handle everything I think it is best to catch Artifact that failed to combine and retry or legalize under some conditions, the conditions when to retry combine or legalize depend on set of available combines(and maybe it would have to be reduced to set of more basic combines).

In the mean time, I would like to commit D65894 if you don’t have any concerns about it. It will allow us to legalize the instructions blocked by illegal artifacts without trying to improve the generated code.

Sure, let's go with D65894 for start.

Wed, Aug 21, 6:04 AM · Restricted Project
Petar.Avramovic committed rG7f581df64901: [MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD (authored by Petar.Avramovic).
[MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD
Wed, Aug 21, 2:47 AM
Petar.Avramovic committed rL369512: [MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD.
[MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD
Wed, Aug 21, 2:42 AM
Petar.Avramovic closed D66205: [MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD.
Wed, Aug 21, 2:42 AM · Restricted Project
Petar.Avramovic committed rGe406aa791ccc: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT (authored by Petar.Avramovic).
[MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT
Wed, Aug 21, 2:41 AM
Petar.Avramovic committed rL369511: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.
[MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT
Wed, Aug 21, 2:41 AM
Petar.Avramovic closed D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.
Wed, Aug 21, 2:41 AM · Restricted Project
Petar.Avramovic committed rG61bf2675b986: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882 (authored by Petar.Avramovic).
[MIPS GlobalISel] Consider type1 when legalizing shifts after r351882
Wed, Aug 21, 2:32 AM
Petar.Avramovic committed rG5b4c5c2c54be: [MIPS GlobalISel] NarrowScalar G_TRUNC (authored by Petar.Avramovic).
[MIPS GlobalISel] NarrowScalar G_TRUNC
Wed, Aug 21, 2:32 AM
Petar.Avramovic committed rL369510: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882.
[MIPS GlobalISel] Consider type1 when legalizing shifts after r351882
Wed, Aug 21, 2:32 AM
Petar.Avramovic closed D66203: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882.
Wed, Aug 21, 2:32 AM · Restricted Project
Petar.Avramovic committed rL369509: [MIPS GlobalISel] NarrowScalar G_TRUNC.
[MIPS GlobalISel] NarrowScalar G_TRUNC
Wed, Aug 21, 2:32 AM
Petar.Avramovic closed D66202: [MIPS GlobalISel] NarrowScalar G_TRUNC .
Wed, Aug 21, 2:32 AM · Restricted Project

Aug 19 2019

Petar.Avramovic updated the diff for D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.

Removed capture by value in lambda.

Aug 19 2019, 3:56 AM · Restricted Project
Petar.Avramovic updated the diff for D66202: [MIPS GlobalISel] NarrowScalar G_TRUNC .

Removed capture by value in lambda.

Aug 19 2019, 3:54 AM · Restricted Project

Aug 16 2019

Petar.Avramovic added a comment to D66228: [mips] Fix 64-bit address loading in case of applying 32-bit mask to the result.

In getAddrNonPICSym64 Relocation looks to come from another SDValue (Hi bellow)
MipsISD::Hi doesn't seem to be connected with any of the target flags (like MipsII::MO_ABS_HI)

SDValue Shift = DAG.getNode(ISD::SHL ...
Aug 16 2019, 4:25 AM · Restricted Project
Petar.Avramovic added a comment to D66228: [mips] Fix 64-bit address loading in case of applying 32-bit mask to the result.

@sdardis What is the difference between MipsHi and MipsLo SD nodes? Some of their patterns are the same, e.g. :

def : MipsPat<(add GPR64:$hi, (MipsHi (i64 tglobaladdr:$lo))),
              (DADDiu GPR64:$hi, tglobaladdr:$lo)>, ISA_MIPS3, GPR_64, SYM_64;
Aug 16 2019, 3:23 AM · Restricted Project

Aug 15 2019

Petar.Avramovic added a comment to D66228: [mips] Fix 64-bit address loading in case of applying 32-bit mask to the result.

I am not really sure if this is correct way to fix PR42736. I looked in td files and found a few inconsistencies, again I might have misinterpreted something.

Aug 15 2019, 6:26 AM · Restricted Project

Aug 14 2019

Petar.Avramovic added a child revision for D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT: D66205: [MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD.
Aug 14 2019, 2:00 AM · Restricted Project
Petar.Avramovic added a parent revision for D66205: [MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD: D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.
Aug 14 2019, 2:00 AM · Restricted Project
Petar.Avramovic created D66205: [MIPS GlobalISel] NarrowScalar G_ZEXTLOAD and G_SEXTLOAD.
Aug 14 2019, 1:56 AM · Restricted Project
Petar.Avramovic added parent revisions for D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT: D66181: [AArch64][GlobalISel] Add support for narrowScalar of G_ZEXT, D66203: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882.
Aug 14 2019, 1:55 AM · Restricted Project
Petar.Avramovic added a child revision for D66181: [AArch64][GlobalISel] Add support for narrowScalar of G_ZEXT: D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.
Aug 14 2019, 1:55 AM · Restricted Project
Petar.Avramovic added a child revision for D66203: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882: D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.
Aug 14 2019, 1:55 AM · Restricted Project
Petar.Avramovic created D66204: [MIPS GlobalISel] NarrowScalar G_ZEXT and G_SEXT.
Aug 14 2019, 1:54 AM · Restricted Project
Petar.Avramovic added a parent revision for D66203: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882: D66202: [MIPS GlobalISel] NarrowScalar G_TRUNC .
Aug 14 2019, 1:52 AM · Restricted Project
Petar.Avramovic added a child revision for D66202: [MIPS GlobalISel] NarrowScalar G_TRUNC : D66203: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882.
Aug 14 2019, 1:52 AM · Restricted Project
Petar.Avramovic created D66203: [MIPS GlobalISel] Consider type1 when legalizing shifts after r351882.
Aug 14 2019, 1:52 AM · Restricted Project
Petar.Avramovic created D66202: [MIPS GlobalISel] NarrowScalar G_TRUNC .
Aug 14 2019, 1:49 AM · Restricted Project

Aug 9 2019

Petar.Avramovic added a comment to D61787: [GlobalISel Legalizer] Improve artifact combiner.

I don't think that matters as long as you process the rest of the instructions before aborting. That's what D65894 does, it keeps processing the instructions in InstList, then tries to combine the illegal artifacts if there is anything new. Do you have a test case that requires more complicated logic?

Yes, D65894 works perfectly fine for non legal artifacts, but it can't deal with legal artifacts that could be combined.
File withD61787.txt in D65199
line 920 in second file, Inspecting Artifact : %10:_(s32), %11:_(s32) = G_UNMERGE_VALUES %6:_(s64)

Aug 9 2019, 3:40 PM · Restricted Project
Petar.Avramovic added a comment to D61787: [GlobalISel Legalizer] Improve artifact combiner.

In this case, moving %1 to AuxiliaryArtifactList doesn't make any difference because combining %9 will remove it anyway, even if it was in InstList. Since you already check the source registers before legalizing the artifacts, this shouldn't be a problem. What do you think?

Well in this example it is not a problem, but in more complicated case:
moving %1 to AuxiliaryArtifactList means that %1 will be legalized first if %9 failed to combine it away, %9 might be able to combine away the artifact that was produced during legalization of %1.
In general, this patch only combines Artfact from ArtifactList with some auxiliary artifact from AuxiliaryArtifactList, if something gets legalized to legal it will not dispersal from MF during some combine. It's a bit confusing to see instruction said to be legal during legalization but it is not in the final MF.

Aug 9 2019, 8:52 AM · Restricted Project

Aug 8 2019

Petar.Avramovic updated subscribers of D65199: [GlobalISel Legalizer][RFC] Legalization artifact combiner.
Aug 8 2019, 5:48 AM
Petar.Avramovic added a reviewer for D61787: [GlobalISel Legalizer] Improve artifact combiner: paquette.

@volkan Regarding D65894.
Here, artifacts that failed to combine are moved to RetryList and we retry to combine them. Once all of the MachineInstrs that define use operands of our artifact are processed (are not in any of the Observer Lists) we turn artifact into an instruction. This way we have more opportunities for combines. e.g. in /test/AMDGPU/GlobalISel/legalize-unmerge-values.mir , this patch catches G_MERGE/G_UNMERGE combine that D65894 cannot catch because those two are declared legal.
As for the other test changes in D65894, all of them are essentially here.
I also tried test/CodeGen/AArch64/GlobalISel/retry-artifact-combine.mir and got similar output, but with one less copy instr.
there are differences in test/CodeGen/AMDGPU/GlobalISel/legalize-{xor|and|or}.mir
D65894 managed to combine few more G_TRUNC + G_ANYEXT but in the end both patches crash on %0:_(<4 x s8>) = G_TRUNC %29:_(<4 x s32>), because order of combine attempts is different this patch crashed before attempting to combine mentioned G_TRUNC + G_ANYEXT.
Please check if I missed something the this patch does not cover compared to D65894.

Aug 8 2019, 5:47 AM · Restricted Project
Petar.Avramovic updated the diff for D61787: [GlobalISel Legalizer] Improve artifact combiner.

Refresh test changes. Ping.

Aug 8 2019, 5:22 AM · Restricted Project
Petar.Avramovic committed rGcaef93069956: [MIPS GlobalISel] Select jump_table and brjt (authored by Petar.Avramovic).
[MIPS GlobalISel] Select jump_table and brjt
Aug 8 2019, 3:23 AM
Petar.Avramovic committed rL368274: [MIPS GlobalISel] Select jump_table and brjt.
[MIPS GlobalISel] Select jump_table and brjt
Aug 8 2019, 3:20 AM
Petar.Avramovic closed D65861: [MIPS GlobalISel] Select jump_table and brjt.
Aug 8 2019, 3:20 AM · Restricted Project