)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":39177,"name":"Bhavana","display_name":"Bhavana","email":"sortebhavna55@gmail.com","username":"Bhavana"},"change_message_id":"5e53c91a30f16a79f90e8bd1232aea6e76fdc64b","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"c014f814_390e4a12","updated":"2026-08-12 05:22:15.000000000","message":"\"Hi @sean mooney, I have published Patchset 2 addressing all review feedback:\n- Fixed template layout by moving spec to specs/2026.2/approved/ (pep8 / stestr tests now passing).\n- Introduced gpu_pci_weight_multiplier as a dedicated opt-in config option to avoid overloading existing PCI multipliers.\n- Abstracted weigher scoring to evaluate generic PCI capacity density rather than vendor-specific logic.\n- Clarified candidate sorting alignment alongside host weighing in implementation details.\n\nPlease take another look when you have a moment.\"","commit_id":"ef3c49d697cfba07f392b6c8e9cf99077130dd59"}],"specs/2026.2/approved/mig-pci-weigher.rst":[{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":1,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":2,"context_line":"MIG GPU-Aware PCI Host Weigher for Minimal Fragmentation"},{"line_number":3,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":4,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"f7ae5baa_c35e7b73","line":1,"updated":"2026-08-19 12:34:23.000000000","message":"as noted before this file is in the wrong folder. it woudl need to be proposed under 2027.1 not 2026.2\nthis line and the one below is also 1 `\u003d` too long","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":8,"context_line":"filter scheduler to optimize placement of instances requesting NVIDIA"},{"line_number":9,"context_line":"Multi-Instance GPU (MIG) devices or PCI Passthrough GPUs. The goal is to"},{"line_number":10,"context_line":"maximize consolidation (packing) or distribution (spreading) of GPU"},{"line_number":11,"context_line":"allocations without modifying host configurations during runtime."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Problem description"},{"line_number":14,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":5,"id":"821dacdb_b0e08e2b","line":11,"updated":"2026-08-19 12:34:23.000000000","message":"so nova has no mig awareness and mig depending on the genreaion is used to partion the gpu adn expose it ether via mdev or vfio-pci-vairint drivers\n\nso awarenes woudl ineract with 2 completely seperate substems in nova the pci and mdev substystems.","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"1. **Fragmentation**: Instances requesting smaller MIG slices or single PCI"},{"line_number":24,"context_line":"   devices can be scattered across multiple partially filled GPU nodes,"},{"line_number":25,"context_line":"   stranding larger contiguous GPU allocations."},{"line_number":26,"context_line":"2. **Lack of Placement Strategy**: Operators currently lack a configurable"},{"line_number":27,"context_line":"   weighting mechanism to explicitly enforce a \"pack\" or \"spread\" policy for"},{"line_number":28,"context_line":"   GPU workloads."}],"source_content_type":"text/x-rst","patch_set":5,"id":"67ef21b6_4a3bf5a1","line":25,"updated":"2026-08-19 12:34:23.000000000","message":"Fragmentation si not really the right way to think about it\n\nnova only suprpot staic partioning of the gpu\n\nwe explicitly do not support reconfiguring the mig configuration when vms are using any mig instance on a physical gpu\n\nso you cannot have fragmentation today of a gpu becasue we do not supprot consuming the same gpu resouce dynmaiclly as 1 large allcoation or 2 small allcoatiosn\n\nso this is not a vaild expection to have.\n\nbuilding supprot for dynmic partitioning woudl be its own new feature and one we ahve previosuly declared out of scope of nova.","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":25,"context_line":"   stranding larger contiguous GPU allocations."},{"line_number":26,"context_line":"2. **Lack of Placement Strategy**: Operators currently lack a configurable"},{"line_number":27,"context_line":"   weighting mechanism to explicitly enforce a \"pack\" or \"spread\" policy for"},{"line_number":28,"context_line":"   GPU workloads."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"Use Cases"},{"line_number":31,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"a40a5943_e683396d","line":28,"updated":"2026-08-19 12:34:23.000000000","message":"this is valid, we supprot weighing hosts based on teh count of pci devices but not anything more granular then that.\n\nand there was never any supprot for whigh host based on generic mdve aviablity or types\n\nhttps://review.opendev.org/c/openstack/nova-specs/+/951222\nhttps://review.opendev.org/c/openstack/nova/+/953131\n\nwas intended to solve that amoung other usecases","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":38,"context_line":"Proposed change"},{"line_number":39,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"Introduce a new Nova Scheduler Weigher (`GPUPCIWeigher`) in"},{"line_number":42,"context_line":"`nova/scheduler/weights/pci.py` that scores candidate compute hosts based on"},{"line_number":43,"context_line":"their available PCI Passthrough / MIG profile inventory density."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"Scope Limitations (Out of Scope):"},{"line_number":46,"context_line":"---------------------------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"470c567e_66bf30e0","line":43,"range":{"start_line":41,"start_character":0,"end_line":43,"end_character":63},"updated":"2026-08-19 12:34:23.000000000","message":"how will you know its a mig device or gpu?\n\nmdev based gpus are not tracked in the pci tracker\nand vGPUs usign vfio-pci varint driver are not tracked as gpus in the pci tracker so there is nothignin the pci devspec or in the nova db to identify the device as a mig device","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":49,"context_line":"* **No Workload Rebalancing**: Nova will NOT perform or trigger dynamic"},{"line_number":50,"context_line":"  instance migrations or re-scheduling solvers."},{"line_number":51,"context_line":"* **No nova-manage changes**: No CLI tools or admin routines will be"},{"line_number":52,"context_line":"  introduced in Nova."},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"Scheduler Implementation Details:"},{"line_number":55,"context_line":"---------------------------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"2c4dc602_1f0aa90a","line":52,"updated":"2026-08-19 12:34:23.000000000","message":"ack good to set these out up front","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":67,"context_line":"     highest ratio of already-allocated PCI/MIG inventory."},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"   * **Negative Multiplier (Spreading)**: Higher scores given to hosts with"},{"line_number":70,"context_line":"     completely idle GPU topology."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"4. Ensure alignment with allocation candidate sorting so compute node selection"},{"line_number":73,"context_line":"   ranks the intended device profiles accurately."}],"source_content_type":"text/x-rst","patch_set":5,"id":"b8eaf8f0_079e3d87","line":70,"updated":"2026-08-19 12:34:23.000000000","message":"we typiclly spread by default with positive number meanign spread more agressively however the existing pci filter does the invers so this woudl behvior the saem sas the exsting pci weiher\n\nhttps://github.com/openstack/nova/blob/master/nova/scheduler/weights/pci.py#L48\n\n```\n\"\"\"Higher weights win. We want to keep PCI hosts free unless needed.\n\n        Prefer hosts with the least number of PCI devices. If the instance\n        requests PCI devices, this will ensure a stacking behavior and reserve\n        as many totally free PCI hosts as possible. If PCI devices are not\n        requested, this will ensure hosts with PCI devices are avoided\n        completely, if possible.\n        \"\"\"\n```","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9ddce7bba14e276adb92391e2642b6ade25fb9f6","unresolved":true,"context_lines":[{"line_number":69,"context_line":"   * **Negative Multiplier (Spreading)**: Higher scores given to hosts with"},{"line_number":70,"context_line":"     completely idle GPU topology."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"4. Ensure alignment with allocation candidate sorting so compute node selection"},{"line_number":73,"context_line":"   ranks the intended device profiles accurately."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Alternatives"},{"line_number":76,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"702de3b2_0a9d633b","line":73,"range":{"start_line":72,"start_character":3,"end_line":73,"end_character":49},"updated":"2026-08-19 12:34:23.000000000","message":"allocation sorting is something that you would be implementing for the first time\n\nwe design the current allocation candidates mechanism to support this but this would be the first actual weigher to take advantage of that so you need to explain how that will be done in more detail. its just sorting the allocation candidates in the host state object.","commit_id":"d1acc0f5b901b600acd2cab07b8841ae88bce292"}],"specs/2026.2/mig-pci-weigher.rst":[{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4b38571da07bbc6bbb91673ddef7f7fd81db06e1","unresolved":true,"context_lines":[{"line_number":20,"context_line":"However, standard PCI filtering lacks a placement scoring mechanism specifically tuned"},{"line_number":21,"context_line":"to GPU capacity density. As a result:"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"1. **Fragmentation**: Instances requesting smaller MIG slices or single PCI devices can"},{"line_number":24,"context_line":"   be scattered across multiple partially filled GPU nodes, stranding larger contiguous"},{"line_number":25,"context_line":"   GPU allocations."},{"line_number":26,"context_line":"2. **Lack of Placement Strategy**: Operators currently lack a configurable weighting"},{"line_number":27,"context_line":"   mechanism to explicitly enforce a \"pack\" (fill GPUs sequentially) or \"spread\" (distribute"},{"line_number":28,"context_line":"   GPU workloads across hosts) scheduling policy."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"Proposed Change"},{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":1,"id":"bcf21b70_d9691fca","line":28,"range":{"start_line":23,"start_character":0,"end_line":28,"end_character":49},"updated":"2026-07-27 11:43:10.000000000","message":"for pci cevice we have a minimapl attempt at that by just counting the number of free devices\n\nhttps://github.com/openstack/nova/blob/master/nova/scheduler/weights/pci.py\n\nwhich allows you to prefer or avoid host based on the raw count of the free pci device but without awarenes of the type of device.","commit_id":"38cde17fe6049f243d623326dd0336525114d81b"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4b38571da07bbc6bbb91673ddef7f7fd81db06e1","unresolved":true,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"Proposed Change"},{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Introduce a new Nova Scheduler Weigher (`PCIWeigher` or `MIGPCIWeigher`) in"},{"line_number":34,"context_line":"`nova/scheduler/weights/pci.py` that scores candidate compute hosts based on their"},{"line_number":35,"context_line":"available PCI Passthrough / MIG profile inventory."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"Scope Limitations (Out of Scope):"},{"line_number":38,"context_line":"---------------------------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"caab63c2_7805b64a","line":35,"range":{"start_line":32,"start_character":1,"end_line":35,"end_character":50},"updated":"2026-07-27 11:43:10.000000000","message":"so im not sure that we shoudl do this in a mig specific way\n\nso the way that nova schdulign woks is frist we prefilter host by asking placment where could the vm fit, then we filter host based on admin policy, affinity and nova spcific information finally we weigh the reusltant set of host and allcoations candiates within the host.\n\nso when we get to the weigher we know that the hsot and the allcoation candaite for that host are valid we are just expressing a policy over which ones to perfer.\n\n\nwe could genericlly add the capabliy to prefer to select allcoation candiatas that pack or sread resouce classes across or within a resocue provider.\n\n\nas a MIG specific feature i am not sure this is somethign that shoudl be in nova.\nas a generic resocue class aware weigher that is configurable that is a more compleing propostion.","commit_id":"38cde17fe6049f243d623326dd0336525114d81b"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4b38571da07bbc6bbb91673ddef7f7fd81db06e1","unresolved":false,"context_lines":[{"line_number":34,"context_line":"`nova/scheduler/weights/pci.py` that scores candidate compute hosts based on their"},{"line_number":35,"context_line":"available PCI Passthrough / MIG profile inventory."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"Scope Limitations (Out of Scope):"},{"line_number":38,"context_line":"---------------------------------"},{"line_number":39,"context_line":"* **No Host Repartitioning**: Nova will NOT attempt to dynamically re-partition or change"},{"line_number":40,"context_line":"  MIG device profiles on compute hosts."},{"line_number":41,"context_line":"* **No Workload Rebalancing**: Nova will NOT perform or trigger dynamic instance migrations"},{"line_number":42,"context_line":"  or re-scheduling solvers. (Re-balancing logic belongs in OpenStack Watcher)."},{"line_number":43,"context_line":"* **No nova-manage changes**: No CLI tools or admin routines will be introduced in Nova."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"Scheduler Implementation Details:"},{"line_number":46,"context_line":"--------------------------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"52e6505f_e6cfd4d9","line":43,"range":{"start_line":37,"start_character":0,"end_line":43,"end_character":88},"updated":"2026-07-27 11:43:10.000000000","message":"yes as a weigher that would not be in scope","commit_id":"38cde17fe6049f243d623326dd0336525114d81b"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4b38571da07bbc6bbb91673ddef7f7fd81db06e1","unresolved":true,"context_lines":[{"line_number":44,"context_line":""},{"line_number":45,"context_line":"Scheduler Implementation Details:"},{"line_number":46,"context_line":"--------------------------------"},{"line_number":47,"context_line":"1. Implement `MIGPCIWeigher` inheriting from `nova.scheduler.weights.BaseHostWeigher`."},{"line_number":48,"context_line":"2. Evaluate host `pci_stats` provided in `HostState`."},{"line_number":49,"context_line":"3. Calculate a weight score based on a configurable multiplier:"},{"line_number":50,"context_line":"   * **Positive Multiplier (Packing)**: Higher scores are given to hosts with the highest"},{"line_number":51,"context_line":"     ratio of already-allocated PCI/MIG inventory, concentrating workloads onto fewer nodes."},{"line_number":52,"context_line":"   * **Negative Multiplier (Spreading)**: Higher scores are given to hosts with completely"},{"line_number":53,"context_line":"     idle GPU topology."},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"Configuration Options"},{"line_number":56,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"fa507269_ca2c8551","line":53,"range":{"start_line":47,"start_character":0,"end_line":53,"end_character":23},"updated":"2026-07-27 11:43:10.000000000","message":"so this is not quite what we woudl want to do in this case.\n\nthe weigher can do 2 things, it can order the host objects  in the list of hosts by porviding a set of caulated wights and it can order the allocation candiates in teh host sate object.\n\nwe do not currently have a weigher that orders the candiates\n\nwe only have an example of filtering candiates \n\nhttps://github.com/openstack/nova/blob/master/nova/scheduler/filters/pci_passthrough_filter.py#L60-L66\nhttps://github.com/openstack/nova/blob/master/nova/scheduler/filters/__init__.py#L60-L94\n\nthe device selection can be influcance by sorting the host_state.allocation_candidates to expres a policy between which gpu to prefer.\n\nsince if your using pci in placment that will influace which gpu can be used by the comptue managere later.\n\ni would add a CandidateWeigherMixin that provides \n```\ndef weight_candidates(self, host_state, sort_predicate):\n```\n\nto provide a generic way to process the candidates and then use that form the exist PCIWeigher.\n\nim not convice this shoudl be a new weigher but rather a resouce class aware extension to the exstign pci one.","commit_id":"38cde17fe6049f243d623326dd0336525114d81b"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"4b38571da07bbc6bbb91673ddef7f7fd81db06e1","unresolved":true,"context_lines":[{"line_number":57,"context_line":""},{"line_number":58,"context_line":"A new configuration option group/key will be added to `nova.conf`:"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"* `[filter_scheduler] pci_weight_multiplier` (float, default: 1.0)"},{"line_number":61,"context_line":"  * Multiplier used for weighting PCI/MIG availability. Set to a positive number to"},{"line_number":62,"context_line":"    pack instances, or a negative number to spread instances across hosts."},{"line_number":63,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"24aaa8aa_b1ace3eb","line":60,"range":{"start_line":60,"start_character":22,"end_line":60,"end_character":43},"updated":"2026-07-27 11:43:10.000000000","message":"this already exists and is used for the relative multiplier fo the pci weiher\nwe can reuse it for the new weiher or to contol the new behvior.\n\nwhat we will need a new set of confgi options to contol the new bevhior and it shoudl be disabled by default i.e. opt in not opt out.","commit_id":"38cde17fe6049f243d623326dd0336525114d81b"}]}
