private void addSymbol(SymbolTable symbolTable, Address address, String symbolName) {

		Listing listing = currentProgram.getListing();
		Data data = listing.getDefinedDataAt(address);
		if (data != null && data.hasStringValue()) {
			return; // don't add symbol for string (not sure why)
		}

		try {
			Symbol newSymbol =
				symbolTable.createLabel(address, symbolName, SourceType.USER_DEFINED);
			newSymbol.setPrimary();
		}
		catch (InvalidInputException e) {
			// shouldn't happen
			Msg.trace(this, "Unexpected exception", e);
		}

	}
This will return true if enough pushes before top of function.
This will return false if not enough pushes or if not a function.
Ghidra/Features/MicrosoftCodeAnalyzer/src/main/java/ghidra/app/plugin/prototype/MicrosoftCodeAnalyzerPlugin/PropagateExternalParametersAnalyzer.java