Displaying 20 results from an estimated 33 matches for "countabl".
Did you mean:
countable
2007 Apr 30
4
Mocking with Calculated Results
...else => nil
This roughly approximates how ActiveRecord::find works in this case
(neglecting the optional parameters).
My question is: Is this calculation of the return value a bad thing,
and if so, how better to accomplish it?
Thanks
---------
module SettingsMock
def setup_mock
@countable = mock(''countable'')
@countable.stub!(:count).and_return(1)
@countable.stub!(:full_messages).and_return([''a message''])
@setting = mock_model Setting do |m|
m.stub!(:save).and_return(true)
m.stub!(:destroy)
m.stub!(:errors).and_...
2012 Nov 14
0
[LLVMdev] Is infinite empty loop dead code?
...2012 at 12:22:33AM -0800, Shuxin Yang wrote:
> I do some google, I cannot find the answer...
> I check C std, I cannot find answer either.
>
> Delete infinite empty loop is boring, but if C/C++ lawyers could tell it
> is safe to to so,
> it would obviate the need to prove a non-countable loop infinite or not
> before
> DCE can delete it.
>
> That is the answer I'm waiting for to delete a disgusting dead
> non-countable loop in my way.
Perhaps Duncan will give you a proper keyword to search in GCC/LLVM
ML archieve. I found a page [1], and iiuc, the C standa...
2012 Nov 14
6
[LLVMdev] Is infinite empty loop dead code?
I do some google, I cannot find the answer...
I check C std, I cannot find answer either.
Delete infinite empty loop is boring, but if C/C++ lawyers could tell it
is safe to to so,
it would obviate the need to prove a non-countable loop infinite or not
before
DCE can delete it.
That is the answer I'm waiting for to delete a disgusting dead
non-countable loop in my way.
On 11/14/2012 12:14 AM, Duncan Sands wrote:
> Hi Shuxin,
>
>> Is it legal to delete empty infinite loop like this : "while(1)
&...
2012 Nov 14
1
[LLVMdev] Is infinite empty loop dead code?
Hi, dear Wenren:
Thank you so much for sharing this info. I really appreciate it.
Now I can move on deleting dead non-countable loops.
Thank you again!
Shuxin
On 11/14/12 12:56 AM, 陳韋任 (Wei-Ren Chen) wrote:
> On Wed, Nov 14, 2012 at 12:22:33AM -0800, Shuxin Yang wrote:
>> I do some google, I cannot find the answer...
>> I check C std, I cannot find answer either.
>>
>> Delete infinite empty lo...
2012 Nov 14
2
[LLVMdev] Is infinite empty loop dead code?
If the code is unreachable, such code is easy to be removed, and should
be removed.
If it is reachable, that is bit difficult to tell. Now that C std
already give compiler such permit,
perhaps we don't have to keep in sync with gcc. Otherwise, it is very
difficult to delete dead
non-countable loop.
One might argue, do you see many dead non-countable loops?
I don't know the answer, but in the case I'm working on the loop was not
dead at beginning,
but after I recognize some idiom and remove some statements out of the
loop. Then the loop becomes dead.
I hope DCE to get rid of...
2012 Nov 14
8
[LLVMdev] Is infinite empty loop dead code?
Hi, All:
Is it legal to delete empty infinite loop like this : "while(1) {}"?
It is interesting that both llvm and gcc keep the loop, however Open64
delete it.
If it is safe to delete this loop, it would be lot easier to delete
non-obvious
dead loop like following as compiler doesn't need to prove if the loop
in question
is infinite or not. Currently llvm is not able to
2012 Nov 14
0
[LLVMdev] Is infinite empty loop dead code?
Hi Shuxin,
> Is it legal to delete empty infinite loop like this : "while(1) {}"?
> It is interesting that both llvm and gcc keep the loop, however Open64 delete it.
this is an endless source of discussion. I suggest you read the GCC and LLVM
mailing list archives if you want to find out more about it.
Ciao, Duncan.
> If it is safe to delete this loop, it would be
2012 Nov 14
2
[LLVMdev] Is infinite empty loop dead code?
Thank you all for the input. Seems that I have to prove a non-countable
loop is finite before I can delete it.
BTW, I think this draft is not clear as to what is "constant expr". The
source code may use symbolic value,
but later on the symbolic value could be proved to be constant. However,
compiler could mistakenly delete the loop before that
point.
T...
2011 Oct 05
1
Needed help with 3 factor anova !!!
I am a student from Poland. What I am interested in is 3 factor anova with R.
Could you please help me find an example with using this method with R?
With all possible countable output for anova as the output presents with 3
factor anova with spss?
I would be glad with any help.
--
View this message in context: http://r.789695.n4.nabble.com/Needed-help-with-3-factor-anova-tp3875620p3875620.html
Sent from the R help mailing list archive at Nabble.com.
2012 Nov 14
0
[LLVMdev] Is infinite empty loop dead code?
On 11/14/2012 1:23 AM, Shuxin Yang wrote:
>
> Is it legal to delete empty infinite loop like this : "while(1) {}"?
If the loop was reachable, the program will not terminate. If you
delete the loop, where is the execution going to go after this point?
You can't arbitrarily insert a branch to somewhere or instructions to
execute. If the loop was unreachable, then it
2012 Jul 25
2
[LLVMdev] Question about an unusual jump instruction
...uot;;
let OutOperandList = (outs GprRegs:$R0);
let InOperandList = (ins GprRegs: $R1, imm16:$dest);
let AsmString = "DECJNZ $R0, $dest";
let isBranch = 1;
let isTerminator = 1;
let Constraints = "$R1 = $R0";
let Defs = [SR];
}
I would like to create an optimization pass to make countable loops faster by
using this instruction.
The simplest loop that I would like to optimize is like:
//////////////////////////
int i = a;
do {
// loop body
--i;
} while (i != 0);
//////////////////////////
After code selection I've something like:
BB0:
%vreg0<def> = COPY %R0;...
2007 Apr 28
7
[ rspec-Patches-9605 ] Patch for ER 9472, shared behaviour
Hi all - I''ve applied (to trunk) Bob Cotton''s patch which supports
shared behaviours (link to tracker below).
I''m still toying w/ names, so please be aware that until this is
released w/ 0.9 it should be considered experimental and there will
NOT be translation support for it. It will definitely be included in
some form - just the names (specifically
2006 Oct 31
2
again on file corruption
Hi,
I've posted the same problem several months ago, You can find my post
there:
http://lists.samba.org/archive/samba/2006-March/119244.html
I summed up all the whole thing: I run a samba server based on slackware
10.2, using samba 3.0.20 with two clients: a windows 98 box and a
windows 2000 box. I've got a share between the two system which hosts an
old spreadsheet program (quattro pro)
2011 Feb 16
5
validates_inclusion_of with range on ruby 1.9
I found out today that Range#include? behaves differently on 1.9 than on 1.8 ( http://rhnh.net/2009/08/03/range-include-in-ruby-1-9 )
In order to deal with various edge cases, instead of just checking whether range.first <= value <= range.last, in ruby 1.9 include? steps through all the values in the range, checking for equality.
This is of course a lot slower - in my case, checking a date
2012 Nov 22
2
[LLVMdev] Disable loop unroll pass
Hi, Gang:
I remember there were different voices when you check-in the code.
I agree with them although I didn't reply your mail in open64's mailing
list.
In the transformation you illustrate, it involves two operations:
1) promote WHILE-loop into DO-loop (i.e noncountable loop to
countable loop)
2) get rid of trip-count dec/inc and compare.
1) is irrelevant to HW loop. Any scalar optimizer should handle 1).
It is not difficult at all to handle 2) in CodeGen and it is unnecessary to
to introduce a Operator just for that purpose.
Shuxin
On 11/22/2012 06:03 A...
2005 Jun 23
2
solving equation system
Hello,
I want to solve some two dimensional equation system with R. Some systems
are not solvable analytically.
Here is an example:
(I) 1/n*sum{from_i=1_to_n}(Xi) = ln lambda + digamma(c)
(II) mean(X) = x / lambda
I want to find lambda and c,
which R-function could do that task?
Carsten
[[alternative HTML version deleted]]
2012 Jul 25
0
[LLVMdev] Question about an unusual jump instruction
...);
> let InOperandList = (ins GprRegs: $R1, imm16:$dest);
> let AsmString = "DECJNZ $R0, $dest";
> let isBranch = 1;
> let isTerminator = 1;
> let Constraints = "$R1 = $R0";
> let Defs = [SR];
> }
>
> I would like to create an optimization pass to make countable loops faster by
> using this instruction.
>
> The simplest loop that I would like to optimize is like:
>
> //////////////////////////
> int i = a;
> do {
> // loop body
> --i;
> } while (i != 0);
> //////////////////////////
>
>
> After code selectio...
2012 Nov 14
0
[LLVMdev] Is infinite empty loop dead code?
On 11/14/2012 12:07 PM, Shuxin Yang wrote:
>
> If it is reachable, that is bit difficult to tell. Now that C std
> already give compiler such permit, perhaps we don't have to keep
> in sync with gcc.
From the C standard (well, draft):
----
6.8.5 Iteration statements
[...]
An iteration statement whose controlling expression is not a constant
expression, that performs no
2012 Nov 14
0
[LLVMdev] Is infinite empty loop dead code?
On Wed, Nov 14, 2012 at 11:24 AM, Shuxin Yang <shuxin.llvm at gmail.com> wrote:
> Thank you all for the input. Seems that I have to prove a non-countable loop
> is finite before I can delete it.
>
> BTW, I think this draft is not clear as to what is "constant expr". The
> source code may use symbolic value,
> but later on the symbolic value could be proved to be constant. However,
> compiler could mistakenly delete the...
2013 Apr 01
1
Image segmentation
Hi,
I work with
remote sensing in Brazil. I would like to know if there is any algorithm or
package that does image segmentation by region growing in R.
Thanks,
Eder.
[[alternative HTML version deleted]]