<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div><b>• gc-5-shadowstack.patch (+59, -406 lines)</b></div><div>With this patch, the <font class="Apple-style-span" face="Courier">LowerGC</font> transformation is adapted to become the <font class="Apple-style-span" face="Courier">ShadowStackCollector</font>.</div></div><div><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Trebuchet MS; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Trebuchet MS; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Trebuchet MS; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Trebuchet MS; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Trebuchet MS; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Trebuchet MS; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><div><br class="khtml-block-placeholder"></div><div><font class="Apple-style-span" face="Courier">$ llvm-as < simple_ocaml.ll | llc -gc=shadow-stack</font></div><div><font class="Apple-style-span" face="Courier"><br class="webkit-block-placeholder"></font></div><div><font class="Apple-style-span" face="Courier"><br class="webkit-block-placeholder"></font></div><div><font class="Apple-style-span" face="Courier"> .text</font></div><div><font class="Apple-style-span" face="Courier"> .align 4,0x90</font></div><div><font class="Apple-style-span" face="Courier"> .globl _fun</font></div><div><font class="Apple-style-span" face="Courier">_fun:</font></div><div><font class="Apple-style-span" face="Courier"> subl $44, %esp</font></div><div><font class="Apple-style-span" face="Courier"> movl L_llvm_gc_root_chain$non_lazy_ptr, %eax</font></div><div><font class="Apple-style-span" face="Courier"> movl (%eax), %ecx</font></div><div><font class="Apple-style-span" face="Courier"> movl %ecx, 16(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl $2, 20(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl $0, 28(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl $0, 24(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl $0, 12(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> leal 12(%esp), %ecx</font></div><div><font class="Apple-style-span" face="Courier"> movl %ecx, 24(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl $0, 36(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl $0, 32(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> leal 16(%esp), %ecx</font></div><div><font class="Apple-style-span" face="Courier"> movl %ecx, (%eax)</font></div><div><font class="Apple-style-span" face="Courier"> movl $0, 8(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> leal 8(%esp), %eax</font></div><div><font class="Apple-style-span" face="Courier"> movl %eax, 32(%esp)</font></div><div><font class="Apple-style-span" face="Courier"> movl 48(%esp), %eax</font></div><div><font class="Apple-style-span" face="Courier"> movl %eax, 12(%esp)</font></div><div><font class="Apple-style-span" face="Courier">LBB1_1: # bb.loop</font></div><div><font class="Apple-style-span" face="Courier"> movl 12(%esp), %eax</font></div><div><font class="Apple-style-span" face="Courier"> movl 4(%eax), %eax</font></div><div><font class="Apple-style-span" face="Courier"> testl %eax, %eax</font></div><div><font class="Apple-style-span" face="Courier"> je LBB1_1 # bb.loop</font></div><div><font class="Apple-style-span" face="Courier">LBB1_2: # bb.end</font></div><div><font class="Apple-style-span" face="Courier"> movl $8, (%esp)</font></div><div><font class="Apple-style-span" face="Courier"> call L_malloc$stub</font></div><div><font class="Apple-style-span" face="Courier"> movl 12(%esp), %ecx</font></div><div><font class="Apple-style-span" face="Courier"> movl %ecx, 4(%ecx)</font></div><div><font class="Apple-style-span" face="Courier"> movl L_llvm_gc_root_chain$non_lazy_ptr, %ecx</font></div><div><font class="Apple-style-span" face="Courier"> movl 16(%esp), %edx</font></div><div><font class="Apple-style-span" face="Courier"> movl %edx, (%ecx)</font></div><div><font class="Apple-style-span" face="Courier"> addl $44, %esp</font></div><div><font class="Apple-style-span" face="Courier"> ret</font></div><div><font class="Apple-style-span" face="Courier"> .data</font></div><div><font class="Apple-style-span" face="Courier"> .comm _llvm_gc_root_chain,4 # llvm_gc_root_chain</font></div><div><font class="Apple-style-span" face="Courier">.section __IMPORT,__jump_table,symbol_stubs,self_modifying_code+pure_instructions,5</font></div><div><font class="Apple-style-span" face="Courier">L_malloc$stub:</font></div><div><font class="Apple-style-span" face="Courier"> .indirect_symbol _malloc</font></div><div><font class="Apple-style-span" face="Courier"> hlt ; hlt ; hlt ; hlt ; hlt</font></div><div><font class="Apple-style-span" face="Courier"><br class="webkit-block-placeholder"></font></div><div><font class="Apple-style-span" face="Courier">.section __IMPORT,__pointers,non_lazy_symbol_pointers</font></div><div><font class="Apple-style-span" face="Courier">L_llvm_gc_root_chain$non_lazy_ptr:</font></div><div><font class="Apple-style-span" face="Courier"> .indirect_symbol _llvm_gc_root_chain</font></div><div><font class="Apple-style-span" face="Courier"> .long 0</font></div><div><font class="Apple-style-span" face="Courier"> .subsections_via_symbols</font></div><div><br class="webkit-block-placeholder"></div>— Gordon<br class="Apple-interchange-newline"></span></span></span></span></span></span> </div><br></body></html>