[cfe-commits] r82735 - /cfe/trunk/lib/CodeGen/CGExpr.cpp

Fariborz Jahanian fjahanian at apple.com
Sat Sep 26 10:24:01 PDT 2009


I have a test cases which are executable only. Passing a bad address  
need an executable test.
In fact it is dejagnu test objc-gc-assign-ivar-1.m.

- fariborz

On Sep 26, 2009, at 9:34 AM, Daniel Dunbar wrote:

> Test case?
>
> - Daniel
>
> On Thu, Sep 24, 2009 at 5:00 PM, Fariborz Jahanian <fjahanian at apple.com 
> > wrote:
>> Author: fjahanian
>> Date: Thu Sep 24 19:00:20 2009
>> New Revision: 82735
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=82735&view=rev
>> Log:
>> Fixed another code gen bug in objc's new write-barrier API.
>>
>>
>> Modified:
>>    cfe/trunk/lib/CodeGen/CGExpr.cpp
>>
>> Modified: cfe/trunk/lib/CodeGen/CGExpr.cpp
>> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGExpr.cpp?rev=82735&r1=82734&r2=82735&view=diff
>>
>> = 
>> = 
>> = 
>> = 
>> = 
>> = 
>> = 
>> = 
>> = 
>> =====================================================================
>> --- cfe/trunk/lib/CodeGen/CGExpr.cpp (original)
>> +++ cfe/trunk/lib/CodeGen/CGExpr.cpp Thu Sep 24 19:00:20 2009
>> @@ -494,11 +494,12 @@
>>       assert(Dst.getBaseIvarExp() && "BaseIvarExp is NULL");
>>       const llvm::Type *ResultType = ConvertType(getContext 
>> ().LongTy);
>>       llvm::Value *RHS = EmitScalarExpr(Dst.getBaseIvarExp());
>> +      llvm::Value *dst = RHS;
>>       RHS = Builder.CreatePtrToInt(RHS, ResultType,  
>> "sub.ptr.rhs.cast");
>>       llvm::Value *LHS =
>>         Builder.CreatePtrToInt(LvalueDst, ResultType,  
>> "sub.ptr.lhs.cast");
>>       llvm::Value *BytesBetween = Builder.CreateSub(LHS, RHS,  
>> "ivar.offset");
>> -      CGM.getObjCRuntime().EmitObjCIvarAssign(*this, src, LvalueDst,
>> +      CGM.getObjCRuntime().EmitObjCIvarAssign(*this, src, dst,
>>                                               BytesBetween);
>>     }
>>     else if (Dst.isGlobalObjCRef())
>>
>>
>> _______________________________________________
>> cfe-commits mailing list
>> cfe-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
>>




More information about the cfe-commits mailing list