Hello Hamid,
Never having had the pleasure of visiting Chile I can't comment on the lifestyle or cost of living there, so I will defer to the comments of those local members.
I will agree that crime is an issue in Brazil that deserves a lot of consideration. That said, most petty crimes here in Brazil are crimes of opportunity which one can usually always avoid by taking common sense precautions that should be adopted wherever you travel. Serious crime here is almost always related to organized crime or drug trafficking, so if you aren't hanging around with the wrong people and you don't get involved with drugs in any way you really don't need to worry about that too much. I've lived in Brazil for over 12 years now and I've never had any problems at all. I've lived in several different Brazilian cities in 5 different states, in some pretty shabby areas, still alive and well and never had a scratch!!!
The cost of living in Brazil is high, again with some planning and common sense that too can be reduced to an acceptable level. One thing that you can't do anything about here is the tax load placed on everybody. There are a number (usually 6) different taxes built into the price of absolutely everything you buy or services you use here. For example, your overall bill at the supermarket ends up being about 22% on average taxes. Some foods and other items are taxed less, but other have taxes as high as 60%. Any imported goods like televisions, computers, telephones, etc. have on top of everything else a 60% import tax pricing them right out of the range of the average Brazilian and forcing them to buy inferior quality Brazilian made products.
I don't know what it's like in Chile, but there is one thing about Brazil that drives most foreigners absolutely crazy and is responsible for many leaving the country and that is the crushing bureaucracy that is imposed upon both Brazilians and foreigners alike. Even the simplest everyday tasks here are buried under mountains of paperwork and red tape. It's absolutely insane and there is no good reason for any of it.
I invite you to check out the Brazil Forum, especially the topics I've posted (with stickies) at the top of the first Brazil Forum page, they're all packed with tons of information and advice that will be essential should you choose Brazil as your final landing place!
https://www.expat.com/forum/viewforum.php?id=511
The Brazilian people are warm, friendly and welcome foreigners with open arms. The weather is always warm (sometimes too hot for my liking) and the lifestyle in smaller cities is relaxed and laid back. Big cities like São Paulo, Rio, Belo Horizonte are just go, go, go. They're fine for job opportunities and earning money, but they move at a hectic pace and you can't escape from the rat race.
Cheers,
William James Woodward, EB Experts Team