@Test
	public void testFallthroughOverridesAndDelaySlots() throws AddressFormatException {
		//verify that the test program contains the instructions for the test
		Address calldsFunc3Addr = defaultSpace.getAddress(CALLDS_FUNC3_100022);
		Instruction calldsFunc3 = program.getListing().getInstructionAt(calldsFunc3Addr);
		assertNotNull(calldsFunc3);
		assertEquals("callds 0x" + func3Addr.toString(), calldsFunc3.toString());

		Address user3Addr = defaultSpace.getAddress(USER_THREE_100024);
		Instruction user3 = program.getListing().getInstructionAt(user3Addr);
		assertNotNull(user3);
		assertEquals("_user_three", user3.toString());

		Address subAddr = defaultSpace.getAddress(SUB_R0_R0_100026);
		Instruction sub = program.getListing().getInstructionAt(subAddr);
		assertNotNull(sub);
		assertEquals("sub r0,r0", sub.toString());

		Address addAddr = defaultSpace.getAddress(ADD_R0_R0_100028);
		Instruction add = program.getListing().getInstructionAt(addAddr);
		assertNotNull(add);
		assertEquals("add r0,r0", add.toString());

		//get the pcode for the callds instruction before any overrides applied
		PcodeOp[] calldsUnmodified = calldsFunc3.getPcode(false);
		assertTrue(calldsUnmodified.length == 3);
		assertTrue(calldsUnmodified[0].getOpcode() == PcodeOp.CALLOTHER);  //from delay slot
		assertTrue(calldsUnmodified[1].getOpcode() == PcodeOp.COPY);       //save return address to lr
		assertTrue(calldsUnmodified[1].getNumInputs() == 1);
		//return address should be address of instruction after instruction in delay slot
		assertTrue(calldsUnmodified[1].getInput(0).getOffset() == subAddr.getOffset());
		assertTrue(calldsUnmodified[2].getOpcode() == PcodeOp.CALL);

		//get the pcode for the instruction in the delay slot before any overrides applied
		PcodeOp[] user3Unmodified = user3.getPcode(false);
		assertTrue(user3Unmodified.length == 1);
		assertTrue(user3Unmodified[0].getOpcode() == PcodeOp.CALLOTHER);

		//test that requesting overrides when there aren't any is the same as not requesting
		//overrides
		assertTrue(equalPcodeOpArrays(calldsFunc3.getPcode(false), calldsFunc3.getPcode(true)));
		assertTrue(equalPcodeOpArrays(user3.getPcode(false), user3.getPcode(true)));

		//apply fallthrough override on instruction in delay slot
		int tid = program.startTransaction("test");
		user3.setFallThrough(addAddr);
		program.endTransaction(tid, true);

		//verify that there are no changes if you request no overrides
		assertTrue(equalPcodeOpArrays(calldsUnmodified, calldsFunc3.getPcode()));
		assertTrue(equalPcodeOpArrays(calldsUnmodified, calldsFunc3.getPcode(false)));
		assertTrue(equalPcodeOpArrays(user3Unmodified, user3.getPcode()));
		assertTrue(equalPcodeOpArrays(user3Unmodified, user3.getPcode(false)));

		//verify that the fallthrough override does nothing to the instruction in the delay slot
		assertTrue(equalPcodeOpArrays(user3Unmodified, user3.getPcode(true)));

		//clear the fallthrough override on the instruction in the delay slot
		tid = program.startTransaction("test");
		user3.clearFallThroughOverride();
		program.endTransaction(tid, true);

		//apply fallthrough override on instruction with a delay slot
		tid = program.startTransaction("test");
		calldsFunc3.setFallThrough(addAddr);
		program.endTransaction(tid, true);

		//verify that there are no changes if you request no overrides
		assertTrue(equalPcodeOpArrays(calldsUnmodified, calldsFunc3.getPcode()));
		assertTrue(equalPcodeOpArrays(calldsUnmodified, calldsFunc3.getPcode(false)));
		assertTrue(equalPcodeOpArrays(user3Unmodified, user3.getPcode()));
		assertTrue(equalPcodeOpArrays(user3Unmodified, user3.getPcode(false)));

		PcodeOp[] calldsModified = calldsFunc3.getPcode(true);

		//verify that a BRANCH op is appended to the pcode for callds
		assertTrue(calldsModified.length == calldsUnmodified.length + 1);
		for (int i = 0; i < calldsUnmodified.length; ++i) {
			assertTrue(equalPcodeOps(calldsModified[i], calldsUnmodified[i]));
		}
		assertTrue(calldsModified[3].getOpcode() == PcodeOp.BRANCH);
		assertTrue(calldsModified[3].getInput(0).isAddress());
		assertTrue(calldsModified[3].getInput(0).getOffset() == addAddr.getOffset());
	}
Tests that fallthrough overrides:
  1) work as expected when applied to instructions with delay slots
  2) have no effect when applied to instructions in delay slots
@throws AddressFormatException if {@code AddressSpace.getAddress} throws it
Ghidra/Test/IntegrationTest/src/test.slow/java/ghidra/program/model/pcode/PcodeEmitContextTest.java