protected long ptrval(Program program, Address addr) throws MemoryAccessException {
		switch (addr.getPointerSize()) {
			case 2:
				return readWord(program, addr);
			case 4:
				return readDWord(program, addr);
			case 8:
				long base = readDWord(program, addr);
				// long ex = readDWord(program, addr.add(4));
				// if (ex == 0) {
				// return (ex << 32) + base;
				// }
				return base;

			default:
				throw new AddressTranslationException(
					"Don't know how to make a " + addr.getPointerSize() + "-byte pointer");
		}
	}
Reads a pointer-size value from <code>program</code> at <code>addr</code>
@param program Program to read from
@param addr Address to read from
@return The value of the pointer reference
@throws MemoryAccessException if the data can't be read
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/exceptionhandlers/gcc/AbstractDwarfEHDecoder.java