```python
def max_path_sum(tri, m, n):
    """
    Finds the maximum total path sum in a given triangle using a bottom-up
    dynamic programming approach.

    The function modifies the triangle in-place. It starts from the second to
    last row and for each element, it adds the maximum of the two elements
    directly below it. This process is repeated upwards until the top element
    is reached. The top element will then contain the maximum path sum.

    Args:
        tri (list of list of int): The triangle.
        m (int): The number of rows in the triangle.
        n (int): The number of columns in the last row (should be equal to m).

    Returns:
        int: The maximum total path sum from top to bottom.
    """
    # Iterate from the second to last row up to the top row.
    for i in range(m - 2, -1, -1):
        # Iterate through each element in the current row.
        for j in range(len(tri[i])):
            # Update the current element with the sum of itself and the
            # maximum of its two children in the row below.
            tri[i][j] += max(tri[i + 1][j], tri[i + 1][j + 1])

    # The top element of the triangle will now contain the maximum path sum.
    return tri[0][0]

```