You will require to implement a custom rule as there are no rules OOTB Sitecore that allows the comparison of total engagement value of goals. The current rules about the Sitecore goals are mainly attached to the contact.
To retrieve the goals total engagement value, you can do the following:
var goalDefinitionManager = ServiceLocator.ServiceProvider.GetDefinitionManagerFactory().GetDefinitionManager<Sitecore.Marketing.Definitions.Goals.IGoalDefinition>();
// Get by ID and culture. Will get the latest active version.
// Pass in boolean true or false as 3rd parameter to return the inactive goal or not
Sitecore.Marketing.Definitions.Goals.IGoalDefinition goalOne = goalDefinitionManager.Get(goalId, CultureInfo.InvariantCulture);
var totalEngagementValue = goalOne.EngagementValuePoints;
The above code will be used in your custom personalization rule. You may have a rule where you can configure the 2 goals then perform the comparison
So the rule will look like
Is Goal specific greater than Goal specific
specific is a selection that allows you to select the Goal Id.
You'll need to configure the rule twice where you will alter the goal position in the rule.
More information about Goals can be found here.