Commit 0ac74914 authored by Raphael von der Grün's avatar Raphael von der Grün Committed by yb9976
Browse files

Fix typos and language in some comments

parent 33eddd21
......@@ -18,7 +18,7 @@
/**
* @ingroup adt
* @defgroup pdeq Double Ended Queue
* Implementation if a double ended queue data structure for generic pointers
* Implementation of a double ended queue data structure for generic pointers
* @{
*/
......
......@@ -41,7 +41,7 @@ FIRM_API void analyze_irg_args(ir_graph *irg);
* has on optimization possibility. Higher values allows
* higher optimization with procedure cloning.
*
* The values are calculation on demand only.
* The values are calculated on demand only.
*/
FIRM_API unsigned get_method_param_weight(ir_entity *ent, size_t pos);
......
......@@ -307,7 +307,7 @@ FIRM_API void proc_cloning(float threshold);
* and for address expression.
* Works only if Constant folding is activated.
*
* Uses loop information to detect loop-invariant (i.e. contant
* Uses loop information to detect loop-invariant (i.e. constant
* inside the loop) values.
*
* See Muchnik 12.3.1 Algebraic Simplification and Reassociation of
......
......@@ -245,9 +245,9 @@ enum args_weight {
};
/**
* Compute the weight of a method parameter
* Computes the weight of a method parameter
*
* @param arg The parameter them weight muss be computed.
* @param arg The parameter whose weight is to be computed.
*/
static unsigned calc_method_param_weight(ir_node *arg)
{
......@@ -352,7 +352,7 @@ static void analyze_method_params_weight(ir_entity *ent)
size_t nparams = get_method_n_params(mtp);
ent->attr.mtd_attr.param_weight = NEW_ARR_F(unsigned, nparams);
/* If the method haven't parameters we have nothing to do. */
/* If the method has no parameters, we have nothing to do */
if (nparams <= 0)
return;
......
......@@ -190,13 +190,13 @@ static void process_call(ir_node *call, ir_entity *callee, q_set *hmap)
* magic. */
/* In this for loop we collect the calls, that have
an constant parameter. */
a constant parameter. */
size_t const n_params = get_Call_n_params(call);
for (size_t i = n_params; i-- > 0;) {
ir_node *const call_param = get_Call_param(call, i);
if (is_Const(call_param)) {
/* we have found a Call to collect and we save the informations,
* which we need.*/
/* we have found a Call to collect and we save the information
* we need.*/
if (!hmap->map)
hmap->map = new_pset(entry_cmp, 8);
......@@ -208,8 +208,9 @@ static void process_call(ir_node *call, ir_entity *callee, q_set *hmap)
key->weight = 0.0F;
key->next = NULL;
/* We insert our information in the set, where we collect the calls.*/
/* Insert entry or get existing equivalent entry */
entry_t *const entry = (entry_t*)pset_insert(hmap->map, key, hash_entry(key));
/* Free memory if entry already is in set */
if (entry != key)
obstack_free(&hmap->obst, key);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment