During compilation, the AST is traversed and used to generate IR instructions. One important concept to grasp is that IR is a very low level sequence of operations. As such, it does not perform implicit conversions or anything of that nature: everything must be done explicitly.
Some common functions of interest:
apply_type_conversion - This function converts a value of one type to another if possible. Implicit versus explicit conversions are controlled via a parameter.
arithmetic_result_type, et. al. - A set of functions that determine the result type of applying an operation to input values.
validate_assignment - Determines if an rvalue can be assigned to an lvalue of a particular type. Allowed implicit conversions will be applied if necessary.
do_assignment - Assigns an rvalue to an lvalue if possible using validate_assignment.
ast_expression::hir - Converts an expression node in the AST to a set of IR instructions.
process_initializer - Applies an initializer expression to a variable.
ast_struct_specifier::hir - Builds an aggregate type to represent a declared structure.
ast_cbuffer_declaration::hir - Builds a struct for the constant buffer layout and stores it as a uniform block.
process_mul - Special code to handle the HLSL intrinsic mul.
match_function_by_name - Looks up a function signature based on name and the list of input parameters.
rank_parameter_lists - Compares two parameter lists and assigns a numerical rank indicating how closely the lists match. This is a helper function used to perform overload resolution: the signature with the lowest rank wins and a function call is declared ambiguous if any signature has the same rank as the lowest ranking signature. A rank of zero indicates an exact match.
gen_texture_op - Handles method calls for builtin HLSL texture and sampler objects.
_mesa_glsl_initialize_functions - Generates builtin functions for HLSL intrinsics. Most functions (e.g. sin, cos) generate IR code to perform the operation but some (e.g. transpose, determinant) leave in function calls deferring the operation to the driver's GLSL compiler.