A method for avoiding memory access hazards for a program, said program comprising an algorithm for encoding or decoding an error control code, the method comprising: determining, by a computing system, a sequence of memory accesses for the program during compilation of the program; generating, by the computing system, information specifying memory access constraints based on the sequence of memory accesses, wherein the information is usable to avoid memory access hazards for the sequence of memory accesses, wherein the generating is performed during the compilation of the program; and configuring, by the computing system, circuitry using the information, wherein the circuitry is included in or coupled to a memory, wherein after said configuring the circuitry is operable to perform memory access requests to the memory corresponding to the sequence of memory accesses while avoiding the memory access hazards by stalling ones of the memory access requests, wherein the circuitry is configured to avoid the memory access hazards without receiving other information indicating the memory access hazards; and wherein the configuring is performed by transferring the information to an interlock table, wherein an entry in said interlock table indicates a number of read operations that must occur prior to performance of a write operation, a number of write operations that must occur prior to performance of a read operation, or a token value for a particular memory access operation in the sequence of memory accesses, wherein the token value indicates a number of subsequent read or write operations to allow to occur before a stall to avoid a next potential hazard. determining, by a computing system, a sequence of memory accesses for the program during compilation of the program; generating, by the computing system, information specifying memory access constraints based on the sequence of memory accesses, wherein the information is usable to avoid memory access hazards for the sequence of memory accesses, wherein the generating is performed during the compilation of the program; and configuring, by the computing system, circuitry using the information, wherein the circuitry is included in or coupled to a memory, wherein after said configuring the circuitry is operable to perform memory access requests to the memory corresponding to the sequence of memory accesses while avoiding the memory access hazards by stalling ones of the memory access requests, wherein the circuitry is configured to avoid the memory access hazards without receiving other information indicating the memory access hazards; and wherein the configuring is performed by transferring the information to an interlock table, wherein an entry in said interlock table indicates a number of read operations that must occur prior to performance of a write operation, a number of write operations that must occur prior to performance of a read operation, or a token value for a particular memory access operation in the sequence of memory accesses, wherein the token value indicates a number of subsequent read or write operations to allow to occur before a stall to avoid a next potential hazard. a number of read operations that must occur prior to performance of a write operation, a number of write operations that must occur prior to performance of a read operation, or a token value for a particular memory access operation in the sequence of memory accesses, wherein the token value indicates a number of subsequent read or write operations to allow to occur before a stall to avoid a next potential hazard.