)]}'
{
  "commit": "f9b080cf5f433fa00678d5cc90b5ef76eb43aa8e",
  "tree": "7cf11881de33f9b706d388130129eb9902bf45aa",
  "parents": [
    "d46998b1dd1a2db10f4372a0ac8eced9c5b5a073"
  ],
  "author": {
    "name": "ZhaoQi",
    "email": "zhaoqi01@loongson.cn",
    "time": "Mon Sep 22 18:05:16 2025 +0800"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Mon Sep 22 18:05:16 2025 +0800"
  },
  "message": "[LoongArch] Custom legalizing ConstantFP to avoid float loads (#158050)\n\nThis commit custom legalize `ConstantFP` using code sequence\nrather than simpily loading the fp values from constant pool.\n\nA new option (`-loongarch-materialize-float-imm\u003d\u003cenum\u003e`) is\nadded to set the maximum number of instructions (including\ncode sequence to generate the value and moving the value to\nFPR) alllowed to be used when materializing floating-point\nimmediates.\n\nThe default value of the option is set to `3` on both LA32 and\nLA64. Which means:\n\n- For `f32` on both LA32 and LA64: `2 insts + movgr2fr.w`;\n  (will cover all `f32` values)\n- For `f64` on LA64: `2 insts + movgr2fr.d`;\n- For `f64` on LA32: `1 inst + movgr2fr.w + movgr2frh.w`.\n  (same inst latency as using constant pool)\n\nThe option can be set in range `0,2-6`. (6 behaves same\nas 5 on LA64.)",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "c45975431d833962116e3d2c97e7b98f9891d6ae",
      "old_mode": 33188,
      "old_path": "llvm/lib/Target/LoongArch/LoongArchFloat32InstrInfo.td",
      "new_id": "690dd73014e57a7f4d30df6f1aba832cc0f491c6",
      "new_mode": 33188,
      "new_path": "llvm/lib/Target/LoongArch/LoongArchFloat32InstrInfo.td"
    },
    {
      "type": "modify",
      "old_id": "965ad8a0a35c6d5226036bf8469db1579b633bdf",
      "old_mode": 33188,
      "old_path": "llvm/lib/Target/LoongArch/LoongArchFloat64InstrInfo.td",
      "new_id": "daefbaa52d42a6d27d8cbf062476d99e1a88046d",
      "new_mode": 33188,
      "new_path": "llvm/lib/Target/LoongArch/LoongArchFloat64InstrInfo.td"
    },
    {
      "type": "modify",
      "old_id": "4b78b14a2a89d07eb8f657b88625919f7e52c02b",
      "old_mode": 33188,
      "old_path": "llvm/lib/Target/LoongArch/LoongArchISelLowering.cpp",
      "new_id": "32baa2d1112709b1520be2b976460b245d9bc991",
      "new_mode": 33188,
      "new_path": "llvm/lib/Target/LoongArch/LoongArchISelLowering.cpp"
    },
    {
      "type": "modify",
      "old_id": "8df3c13f26feae5a35f0e6b89857bd9a4804bcdc",
      "old_mode": 33188,
      "old_path": "llvm/lib/Target/LoongArch/LoongArchISelLowering.h",
      "new_id": "19c85faa9f9ccd2adeadbb44f21acdbb67ece0b2",
      "new_mode": 33188,
      "new_path": "llvm/lib/Target/LoongArch/LoongArchISelLowering.h"
    },
    {
      "type": "modify",
      "old_id": "da8c3e93f68423284ed66b78df1d38c2c38e98df",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/calling-conv-half.ll",
      "new_id": "d111cf2fcfc075283e59cf3efe6ad4fed7a5f0b7",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/calling-conv-half.ll"
    },
    {
      "type": "modify",
      "old_id": "62c2cc999456cf3d2eb5f52ccb9ddf2d96bb212e",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/calling-conv-ilp32d.ll",
      "new_id": "95f9aa514b34057be7ebe00fd273e19d93842a7b",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/calling-conv-ilp32d.ll"
    },
    {
      "type": "modify",
      "old_id": "fe403ec532d8e8449391dd55a23656060e3ae969",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/double-imm.ll",
      "new_id": "0b715cb18f8ad367b89f7a31f99fb575ea983638",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/double-imm.ll"
    },
    {
      "type": "modify",
      "old_id": "006a9e64b190de775169443c7250317149d6b4d3",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/float-imm.ll",
      "new_id": "4611d8801cf2fdbdf1740cbb8eeb2411205a5d2b",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/float-imm.ll"
    },
    {
      "type": "modify",
      "old_id": "e5c848e0f15424b759842547c9de6f5568f91845",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/fsqrt-reciprocal-estimate.ll",
      "new_id": "d875bb98e459395092d0385d2913320d299f9e84",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/fsqrt-reciprocal-estimate.ll"
    },
    {
      "type": "modify",
      "old_id": "4990e7002562dd49a6385b06e255353832e5206b",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/ir-instruction/atomicrmw-fp.ll",
      "new_id": "a6e3f790943aacaf98f2dcd1961bc490ba98285b",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/ir-instruction/atomicrmw-fp.ll"
    },
    {
      "type": "modify",
      "old_id": "0b82ea220d7fb4d6812fb864d918a950065b136e",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/ir-instruction/double-convert.ll",
      "new_id": "ef211139afdf5c545b4e48b206fdeead1d2dcabb",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/ir-instruction/double-convert.ll"
    },
    {
      "type": "modify",
      "old_id": "413702b006b1b5d59b94b882173b2e49611a4922",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/ir-instruction/float-convert.ll",
      "new_id": "8328bb02cf8b5201d1ba52c49f9eb9d21b959a0e",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/ir-instruction/float-convert.ll"
    },
    {
      "type": "modify",
      "old_id": "6e9d26ab362d6022befbfcfc06e664d8e0f0de1f",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/target-abi-from-triple-edge-cases.ll",
      "new_id": "d92de139ce672cff89aa30c183ab5a9b231163a9",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/target-abi-from-triple-edge-cases.ll"
    },
    {
      "type": "modify",
      "old_id": "c8a33725267a2e4fdb76d47d6f5885c258df055b",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/target-abi-from-triple.ll",
      "new_id": "b093f6f6010bcd3c58eaeafd0cdb34061c62e1b6",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/target-abi-from-triple.ll"
    },
    {
      "type": "modify",
      "old_id": "285527fca11cf18b30e56c375f3bf3b4e7f58f0a",
      "old_mode": 33188,
      "old_path": "llvm/test/CodeGen/LoongArch/vector-fp-imm.ll",
      "new_id": "16c9e754fb94d4650d12209fb347e3f076027e1d",
      "new_mode": 33188,
      "new_path": "llvm/test/CodeGen/LoongArch/vector-fp-imm.ll"
    }
  ]
}
