{"title":"简短公告:直线程序的围栏插入在P","authors":"M. Lesani","doi":"10.1145/3087801.3087849","DOIUrl":null,"url":null,"abstract":"Relaxed memory models reorder instructions in the interest of performance. However, reordering of instructions can jeopardize correctness and memory fences should be used to preserve specific orders. Programs that carry explicit fences are over-specified as they are tied to specific architectures and memory models and are hence unportable. On the other hand, once the program specifies the high-level required orders, optimizing compilers can allocate optimum memory fences for multiple architectures. However, the fence insertion problem for general programs is NP-hard. In this paper, we consider fence insertion for straight-line programs. We present a polynomial-time greedy algorithm via reduction to the chain multi-cut problem.","PeriodicalId":324970,"journal":{"name":"Proceedings of the ACM Symposium on Principles of Distributed Computing","volume":"53 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2017-07-25","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"2","resultStr":"{\"title\":\"Brief Announcement: Fence Insertion for Straight-line Programs is in P\",\"authors\":\"M. Lesani\",\"doi\":\"10.1145/3087801.3087849\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Relaxed memory models reorder instructions in the interest of performance. However, reordering of instructions can jeopardize correctness and memory fences should be used to preserve specific orders. Programs that carry explicit fences are over-specified as they are tied to specific architectures and memory models and are hence unportable. On the other hand, once the program specifies the high-level required orders, optimizing compilers can allocate optimum memory fences for multiple architectures. However, the fence insertion problem for general programs is NP-hard. In this paper, we consider fence insertion for straight-line programs. We present a polynomial-time greedy algorithm via reduction to the chain multi-cut problem.\",\"PeriodicalId\":324970,\"journal\":{\"name\":\"Proceedings of the ACM Symposium on Principles of Distributed Computing\",\"volume\":\"53 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2017-07-25\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"2\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Proceedings of the ACM Symposium on Principles of Distributed Computing\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1145/3087801.3087849\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the ACM Symposium on Principles of Distributed Computing","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/3087801.3087849","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
Brief Announcement: Fence Insertion for Straight-line Programs is in P
Relaxed memory models reorder instructions in the interest of performance. However, reordering of instructions can jeopardize correctness and memory fences should be used to preserve specific orders. Programs that carry explicit fences are over-specified as they are tied to specific architectures and memory models and are hence unportable. On the other hand, once the program specifies the high-level required orders, optimizing compilers can allocate optimum memory fences for multiple architectures. However, the fence insertion problem for general programs is NP-hard. In this paper, we consider fence insertion for straight-line programs. We present a polynomial-time greedy algorithm via reduction to the chain multi-cut problem.