<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp, branch users/mingmingl-llvm/samplefdo-profile-format</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>[RISCV] Add helper method for detecting BEXTI or TH_TST is supported. NFC (#157915)</title>
<updated>2025-09-10T19:16:46+00:00</updated>
<author>
<name>Craig Topper</name>
<email>craig.topper@sifive.com</email>
</author>
<published>2025-09-10T19:16:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c6947dad53dacc19d47b4da6b1984ca39ec111f6'/>
<id>c6947dad53dacc19d47b4da6b1984ca39ec111f6</id>
<content type='text'>
These instructions both extract single bit to bit 0 and fill the upper
bits with 0.

There's at least one place where we check for BEXTI but not TH_TST. I
wanted to keep this patch NFC so that will be a follow up fix.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These instructions both extract single bit to bit 0 and fill the upper
bits with 0.

There's at least one place where we check for BEXTI but not TH_TST. I
wanted to keep this patch NFC so that will be a follow up fix.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Prevent folding ADD_LO into load/store if we can't fold all uses. (#155935)</title>
<updated>2025-09-09T16:25:36+00:00</updated>
<author>
<name>Craig Topper</name>
<email>craig.topper@sifive.com</email>
</author>
<published>2025-09-09T16:25:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=f069700928bbc671613a7c4a29b9f8b977cb40ba'/>
<id>f069700928bbc671613a7c4a29b9f8b977cb40ba</id>
<content type='text'>
If we don't fold all uses, we end up with an LUI that is used by an ADDI
and some loads/stores. This requires the LUI to write a different
register than the ADDI or the load/stores uses have to be scheduled
between the LUI and ADDI. It prevents macrofusion of the LUI+ADDI on
CPUs that support it. It prevents the use of PseudoMovAddr which
prevents the LUI+ADDI from being rematerializable.

This is based on a patch we have had in our downstream for a while that
we originally wrote because of macrofusion and rematerialization. I no
longer have any relevant performance or code size numbers for it.

---------

Co-authored-by: Jesse Huang &lt;jesse.huang@sifive.com&gt;
Co-authored-by: Luke Lau &lt;luke_lau@icloud.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If we don't fold all uses, we end up with an LUI that is used by an ADDI
and some loads/stores. This requires the LUI to write a different
register than the ADDI or the load/stores uses have to be scheduled
between the LUI and ADDI. It prevents macrofusion of the LUI+ADDI on
CPUs that support it. It prevents the use of PseudoMovAddr which
prevents the LUI+ADDI from being rematerializable.

This is based on a patch we have had in our downstream for a while that
we originally wrote because of macrofusion and rematerialization. I no
longer have any relevant performance or code size numbers for it.

---------

Co-authored-by: Jesse Huang &lt;jesse.huang@sifive.com&gt;
Co-authored-by: Luke Lau &lt;luke_lau@icloud.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Add th.ext(u) to RISCVDAGToDAGISel::hasAllNBitUsers. (#157133)</title>
<updated>2025-09-05T18:57:26+00:00</updated>
<author>
<name>Craig Topper</name>
<email>craig.topper@sifive.com</email>
</author>
<published>2025-09-05T18:57:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=faab8f76d521d71edc196b899b5496ca2bf634d5'/>
<id>faab8f76d521d71edc196b899b5496ca2bf634d5</id>
<content type='text'>
These instructions are being used by the scalar efficiency SIG to
determine if we should have a standard instruction. Improving our
support for these instructions may give better data for their analysis.

I'll follow up by adding this to RISCVOptWInstrs too which will remove
the 'w' suffixes added here.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These instructions are being used by the scalar efficiency SIG to
determine if we should have a standard instruction. Improving our
support for these instructions may give better data for their analysis.

I'll follow up by adding this to RISCVOptWInstrs too which will remove
the 'w' suffixes added here.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Add changes to have better coverage for qc.insb and qc.insbi (#154135)</title>
<updated>2025-09-03T07:05:38+00:00</updated>
<author>
<name>quic_hchandel</name>
<email>hchandel@qti.qualcomm.com</email>
</author>
<published>2025-09-03T07:05:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=d0363815dd4acde08168e930cb529ee10f86b838'/>
<id>d0363815dd4acde08168e930cb529ee10f86b838</id>
<content type='text'>
Before this patch, the selection for `QC_INSB` and `QC_INSBI` entirely
happens in C++, and does not support more than one non-constant input.

This patch seeks to rectify this shortcoming, by moving the C++ into a
target-specific DAGCombine, and adding `RISCV::QC_INSB`. One advantage
is this simplifies the code for handling `QC_INSBI`, as the C++ no
longer needs to choose between the two instructions based on the
inserted value (this is still done, but via ISel Patterns).

Another advantage of the DAGCombine is that this introduction can also
shift the inserted value to the `QC_INSB`, which our patterns need (and
were previously doing to the constant), and this shift can be
CSE'd/optimised with any prior shifts, if they exist. This allows the
inserted value to be variable, rather than a constant.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Before this patch, the selection for `QC_INSB` and `QC_INSBI` entirely
happens in C++, and does not support more than one non-constant input.

This patch seeks to rectify this shortcoming, by moving the C++ into a
target-specific DAGCombine, and adding `RISCV::QC_INSB`. One advantage
is this simplifies the code for handling `QC_INSBI`, as the C++ no
longer needs to choose between the two instructions based on the
inserted value (this is still done, but via ISel Patterns).

Another advantage of the DAGCombine is that this introduction can also
shift the inserted value to the `QC_INSB`, which our patterns need (and
were previously doing to the constant), and this shift can be
CSE'd/optimised with any prior shifts, if they exist. This allows the
inserted value to be variable, rather than a constant.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Generate QC_INSB/QC_INSBI instructions from OR of AND Imm (#154023)</title>
<updated>2025-08-19T05:44:14+00:00</updated>
<author>
<name>Sudharsan Veeravalli</name>
<email>quic_svs@quicinc.com</email>
</author>
<published>2025-08-19T05:44:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c00b04a7e041bcf0aaf92cf9aacfe536458f1911'/>
<id>c00b04a7e041bcf0aaf92cf9aacfe536458f1911</id>
<content type='text'>
Generate QC_INSB/QC_INSBI from `or (and X, MaskImm), OrImm` iff the
value being inserted only sets known zero bits. This is based on a
similar DAG to DAG transform done in `AArch64`.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Generate QC_INSB/QC_INSBI from `or (and X, MaskImm), OrImm` iff the
value being inserted only sets known zero bits. This is based on a
similar DAG to DAG transform done in `AArch64`.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Use sd_match in trySignedBitfieldInsertInMask (#154152)</title>
<updated>2025-08-19T02:52:06+00:00</updated>
<author>
<name>Sudharsan Veeravalli</name>
<email>quic_svs@quicinc.com</email>
</author>
<published>2025-08-19T02:52:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=8495018a859f2973f7bb8b041ced11f62b9806e6'/>
<id>8495018a859f2973f7bb8b041ced11f62b9806e6</id>
<content type='text'>
This keeps everything in APInt and makes it easier to understand and
maintain.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This keeps everything in APInt and makes it easier to understand and
maintain.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Prioritize zext.h/zext.w over XTheadBb th.extu. (#154186)</title>
<updated>2025-08-18T23:56:57+00:00</updated>
<author>
<name>Craig Topper</name>
<email>craig.topper@sifive.com</email>
</author>
<published>2025-08-18T23:56:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=6c0518a88fccda37e4ab3953f5f55e14c8e03ad1'/>
<id>6c0518a88fccda37e4ab3953f5f55e14c8e03ad1</id>
<content type='text'>
Fixes #154125.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes #154125.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Add CodeGen support for qc.insbi and qc.insb insert instructions (#152447)</title>
<updated>2025-08-14T06:38:28+00:00</updated>
<author>
<name>quic_hchandel</name>
<email>quic_hchandel@quicinc.com</email>
</author>
<published>2025-08-14T06:38:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=71b066e3a2512d582e34a0b5257e12b1177d4bcc'/>
<id>71b066e3a2512d582e34a0b5257e12b1177d4bcc</id>
<content type='text'>
This patch adds CodeGen support for qc.insbi and qc.insb instructions
defined in the Qualcomm uC Xqcibm extension. qc.insbi and qc.insb
inserts bits into destination register from immediate and register
operand respectively.
A sequence of `xor`, `and` &amp; `xor` depending on appropriate conditions
are converted to `qc.insbi` or `qc.insb` which depends on the
immediate's value.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds CodeGen support for qc.insbi and qc.insb instructions
defined in the Qualcomm uC Xqcibm extension. qc.insbi and qc.insb
inserts bits into destination register from immediate and register
operand respectively.
A sequence of `xor`, `and` &amp; `xor` depending on appropriate conditions
are converted to `qc.insbi` or `qc.insb` which depends on the
immediate's value.</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Add RISCVISD::LD_RV32/SD_RV32 to isWorthFoldingAdd. (#151606)</title>
<updated>2025-08-01T05:03:29+00:00</updated>
<author>
<name>Craig Topper</name>
<email>craig.topper@sifive.com</email>
</author>
<published>2025-08-01T05:03:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=a90d653e5934bbf18581579f00e1716743c85820'/>
<id>a90d653e5934bbf18581579f00e1716743c85820</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[RISCV] Handled the uimm9 offset while FrameIndex folding. (#149303)</title>
<updated>2025-07-30T15:43:10+00:00</updated>
<author>
<name>UmeshKalappa</name>
<email>103930015+ukalappa-mips@users.noreply.github.com</email>
</author>
<published>2025-07-30T15:43:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=66b34bc943644c7e20f5c5c22a706a091dd9b053'/>
<id>66b34bc943644c7e20f5c5c22a706a091dd9b053</id>
<content type='text'>
Reverted the https://github.com/llvm/llvm-project/pull/148779 changes
and

- handled the uimm9 offset in eliminateFrameIndex ()
- updated the testcase.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reverted the https://github.com/llvm/llvm-project/pull/148779 changes
and

- handled the uimm9 offset in eliminateFrameIndex ()
- updated the testcase.</pre>
</div>
</content>
</entry>
</feed>
