I got this working, with one specific change although to be honest some other edits may have helped too.
I thought about how drive_data is set up using combinatorial logic, but the outdata register is clocked. Confirmed with behavioural sim, this means that stale data is driven out during the first part of a read cycle, before the address is latched.
I "fixed" this by changing the always block that sets outdata to do so on every clock, meaning the right data gets in there during the setup phase while address is valid on the bus, before the OE strobe comes along.
I also refactored my memory bus handling into a submodule (inverting the control signals).
module emif(
input clk,
input [1:0] addr,
inout [15:0] data,
input ce, // note these signals are active high
input we, // (opposite to the PCB signals)
input oe
);
wire drive_data;
reg [15:0] mem [0:3];
reg [15:0] em_outdata;
assign drive_data = ce && oe && !we;
assign data = drive_data ? em_outdata : 16'bz;
// writes data to small mem
always @ (posedge clk)
begin
if (ce && we) begin
mem[addr] <= data;
end
end
// reads data from small mem
always @ (posedge clk)
begin
em_outdata <= mem[addr];
end
endmodule
No manufacturer will ever release yield data unless they have to for some reason. It's considered a trade secret. So- to answer your question directly, no- it isn't advertised in the industry.
However, there are many engineers whose jobs are to improve the line throughput and end-of-line yield. This often consists of using techniques like binning and block redundancy to make losses off the line function enough to be saleable. Block redundancy is certainly used today. It's pretty easy to analyze:
(failed blocks per part)/(blocks per part)*(failed blocks per part)/(blocks per part)
That'll get you the probability of both parallel blocks failing. I'd doubt you'd end up with a yield as low as 70%, as typically 90% is the minimum acceptable yield.
Best Answer
I think that the origin of the name comes from the convention for flip flops. On a D flipflop the data in pin is generally called D, and the data out pin, Q. Since the memories data bus is bidirectional, a data pin can be D when it is input or Q when it is output hence the name DQ.