Hello, This patch fixes PR5382. The problem is that "bu_ls_rr_sort::operator()" and "td_ls_rr_sort::operator()" call getHeight() and getDepth() methods on SUnit, which can recompute values, what invalidates heap (SPQ). This patch guarantees that height and depth values won't be recomputed. The other solution would be to reheapify SPQ everytime when new SUnit is pop()ed, however I think it would be too expensive. Can anyone look at this? Thanks -Jakub -------------- next part -------------- A non-text attachment was scrubbed... Name: pr5382.patch Type: application/octet-stream Size: 4041 bytes Desc: not available URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20091206/10c8d6e5/attachment.obj> -------------- next part --------------
Thanks. I'm not crazy about this fix but don't see a better one. Dan, what do you think? Evan On Dec 6, 2009, at 10:37 AM, Jakub Staszak wrote:> Hello, > > This patch fixes PR5382. The problem is that "bu_ls_rr_sort::operator()" and "td_ls_rr_sort::operator()" call getHeight() and getDepth() methods on SUnit, which can recompute values, what invalidates heap (SPQ). This patch guarantees that height and depth values won't be recomputed. The other solution would be to reheapify SPQ everytime when new SUnit is pop()ed, however I think it would be too expensive. > > Can anyone look at this? > > Thanks > -Jakub > <pr5382.patch> > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
Maybe Matching Threads
- [LLVMdev] MSVC iterator debugging exception and RegReductionPriorityQueue V2.6
- [LLVMdev] MSVC iterator debugging exception and RegReductionPriorityQueue V2.6
- [LLVMdev] MSVC iterator debugging exception and RegReductionPriorityQueue V2.6
- [LLVMdev] [PATCH] REPOST: Scheduler Fix
- [LLVMdev] [PATCH] REPOST: Scheduler Fix