@Override
	public int assignAddress(DataType dt, PrototypePieces proto, int pos, DataTypeManager dtManager,
			int[] status, ParameterPieces res) {
		PrimitiveExtractor primitives = new PrimitiveExtractor(dt, false, 0, 1024);
		if (!primitives.isValid() || primitives.size() == 0 || primitives.containsHoles()) {
			return FAIL;
		}
		ParameterPieces param = new ParameterPieces();
		int[] primitiveIndex = new int[1];
		primitiveIndex[0] = 0;
		int[] tmpStatus = status.clone();
		ArrayList<Varnode> pieces = new ArrayList<>();
		int typeSize = dt.getLength();
		int sizeLeft = typeSize;
		int iterBase = 0;
		int iterAlt = 0;
		while (sizeLeft > 0) {
			int iterType = getTileClass(primitives, typeSize - sizeLeft, primitiveIndex);
			if (iterType < 0) {
				return FAIL;
			}
			ParamEntry entry;
			if (iterType == 0) {
				iterBase = getFirstUnused(iterBase, baseTiles, tmpStatus);
				if (iterBase == baseTiles.length) {
					return FAIL;		// Out of general registers
				}
				entry = baseTiles[iterBase];
			}
			else {
				iterAlt = getFirstUnused(iterAlt, altTiles, tmpStatus);
				if (iterAlt == altTiles.length) {
					return FAIL;		// Out of alternate registers
				}
				entry = altTiles[iterAlt];
			}
			int trialSize = entry.getSize();
			entry.getAddrBySlot(tmpStatus[entry.getGroup()], trialSize, 1, param);
			tmpStatus[entry.getGroup()] = -1;	// Consume the register
			Varnode vn = new Varnode(param.address, trialSize);
			pieces.add(vn);
			sizeLeft -= trialSize;
		}
		if (sizeLeft < 0) {			// Have odd data-type size
			if (justifyRight) {
				// Initial bytes of first entry are padding
				Varnode vn = pieces.get(0);
				Address addr = vn.getAddress().add(-sizeLeft);
				int sz = vn.getSize() + sizeLeft;
				vn = new Varnode(addr, sz);
				pieces.set(0, vn);
			}
			else {
				int end = pieces.size() - 1;
				Varnode vn = pieces.get(end);
				int sz = vn.getSize() + sizeLeft;
				vn = new Varnode(vn.getAddress(), sz);
				pieces.set(end, vn);
			}
		}
		System.arraycopy(tmpStatus, 0, status, 0, tmpStatus.length);	// Commit resource usage for all the pieces
		res.type = dt;
		res.assignAddressFromPieces(pieces, consumeMostSig, false, resource.getLanguage());
		return SUCCESS;
	}
Constructor for use with decode. Set default configuration.
@param res is the new resource set to associate with this action
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/lang/protorules/MultiSlotDualAssign.java