static void applyTo(PdbParser pdbParser, XmlPullParser xmlParser, TaskMonitor monitor,
			MessageLog log) throws CancelledException {
		Program program = pdbParser.getProgram();
		Listing listing = program.getListing();
		while (xmlParser.hasNext()) {
			if (monitor.isCancelled()) {
				return;
			}
			XmlElement child = xmlParser.next();
			if (child.isEnd() && child.getName().equals("functions")) {
				break;
			}

			String name = child.getAttribute("name");
			int addr = XmlUtilities.parseInt(child.getAttribute("address"));

			Address address = PdbUtil.reladdr(program, addr);

			monitor.setMessage("Applying function at " + address + "...");

//TODO handle functions inside jmps (see pdb_test.exe 0x41100a

			Instruction instr = listing.getInstructionAt(address);
			if (instr == null) {
				DisassembleCommand cmd = new DisassembleCommand(address, null, true);
				cmd.applyTo(program, monitor);
			}

			pdbParser.createSymbol(address, name, true, log);

			Function function = listing.getFunctionAt(address);
			if (function == null) {
				function = createFunction(program, address);
			}
			if (function == null) {
				function = checkInsideThunkJump(program, address, monitor);
			}
			if (function == null) {
				function = checkInsideThunkFunction(program, address, monitor);
			}
			if (function == null) {
				xmlParser.discardSubTree(child);
				continue;
			}

			ApplyStackVariables applyStackVariables =
				new ApplyStackVariables(pdbParser, xmlParser, function);
			applyStackVariables.applyTo(monitor, log);

			ApplyLineNumbers applyLineNumbers = new ApplyLineNumbers(pdbParser, xmlParser, program);
			applyLineNumbers.applyTo(monitor, log);

			xmlParser.next();//skip function end element
		}
	}
Perform parsing and applying of functions 
@param pdbParser PDB parser object
@param xmlParser XML parser position immediately after the functions start element
@param monitor task monitor
@param log message log
@throws CancelledException if task cancelled
Ghidra/Features/PDB/src/main/java/ghidra/app/util/bin/format/pdb/ApplyFunctions.java