<div dir="ltr">Hi, I want to control the program to keep the basic block 32 bytes aligned.<div>So, I use "-align-all-blocks=5" option</div><div>>>></div><div>>>>clang -o simple simple.c -mllvm -align-all-blocks=5<br></div><div>>>></div><div>I checked the assembly code generated in the middle and found that a small portion of the code was not aligned.<br></div><div><br></div><div>So, I want to do it myself. Specifically, the following requirements should be met:</div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div><div>1) The program is aligned at the assembly layer in basic blocks of 32 bytes;</div></div><div>2) All control flow transfer instructions must be the end of a block.</div><div>3) For some reason, some instructions cannot be the beginning of a block, so I have to insert some nops.</div></blockquote><div>What should I do in the LLVM IR level in order for the program to meet the above requirements in the assembly level?<br></div><div>Can you give me some advice on this?<br></div><div>Please help me!</div><div>Thank you!</div></div>