You don't really need to machine flats on the barrel to keep the block in place, but you need to re-torque the screws about 20 times before you finally set them for good. This will get the screws to dig into the barrel deep enough that they won't move.
Putting dimples in the barrel with a drill can also cause you some trouble. If the dimples are not drilled exactly in alignment with the set screws, then as you tighten the screws down, the gas block will "walk" to the center of the dimple. If you are not dead on, then your block is not going to be lined up with the gas port.
Also, always check the gas port alignment before you ever torque the screws down for the first time. The port in the block is drilled through the same hole as the rear set screw. So just install the block, remove the rear screw, spin it upside down, and look through the set screw hole to see if it lines up with the hole in the barrel. Not all gas blocks have the hole drilled the same distance from the rear edge of the block.
Use Purple low strength locktite on any screws 10-32 or smaller. If you use Blue locktite, about 50% of the time, you will not be able to remove a 10-32 screw without putting heat to it. DO NOT put the locktite in the screw hole and then install the screws or it will force the locktite down between the barrel and the block and you will never get it off without putting a lot of heat to it. Put the locktight on the set screws first, then install them in the block.
Trust me on this one guys. I have already made every mistake outlined above......I didn't read this shit in a text book.....I screwed stuff up.
Tony Rumore